]> jfr.im git - yt-dlp.git/blobdiff - yt_dlp/extractor/bbc.py
[compat] Remove more functions
[yt-dlp.git] / yt_dlp / extractor / bbc.py
index 9cb019a491e27b9d199f8930a72ed09fe5e4e649..5ddeef7b5dce2a3ac17dd65e60694a677a530ca4 100644 (file)
@@ -1,16 +1,12 @@
-import xml.etree.ElementTree
 import functools
 import itertools
 import json
 import re
+import urllib.error
+import xml.etree.ElementTree
 
 from .common import InfoExtractor
-from ..compat import (
-    compat_HTTPError,
-    compat_str,
-    compat_urllib_error,
-    compat_urlparse,
-)
+from ..compat import compat_HTTPError, compat_str, compat_urlparse
 from ..utils import (
     ExtractorError,
     OnDemandPagedList,
@@ -391,7 +387,7 @@ def _process_media_selector(self, media_selection, programme_id):
                                 href, programme_id, ext='mp4', entry_protocol='m3u8_native',
                                 m3u8_id=format_id, fatal=False)
                         except ExtractorError as e:
-                            if not (isinstance(e.exc_info[1], compat_urllib_error.HTTPError)
+                            if not (isinstance(e.exc_info[1], urllib.error.HTTPError)
                                     and e.exc_info[1].code in (403, 404)):
                                 raise
                             fmts = []