]> jfr.im git - yt-dlp.git/blobdiff - yt_dlp/extractor/viqeo.py
[ie/orf:on] Improve extraction (#9677)
[yt-dlp.git] / yt_dlp / extractor / viqeo.py
index be7dfa814fda5bfc4531e0ba2db3ac65a8442527..f0a7b5e4436ffbc24a210c34bf8563f0f8151d19 100644 (file)
@@ -1,8 +1,3 @@
-# coding: utf-8
-from __future__ import unicode_literals
-
-import re
-
 from .common import InfoExtractor
 from ..utils import (
     int_or_none,
@@ -12,6 +7,7 @@
 
 
 class ViqeoIE(InfoExtractor):
+    _WORKING = False
     _VALID_URL = r'''(?x)
                         (?:
                             viqeo:|
@@ -20,6 +16,7 @@ class ViqeoIE(InfoExtractor):
                         )
                         (?P<id>[\da-f]+)
                     '''
+    _EMBED_REGEX = [r'<iframe[^>]+\bsrc=(["\'])(?P<url>(?:https?:)?//cdn\.viqeo\.tv/embed/*\?.*?\bvid=[\da-f]+.*?)\1']
     _TESTS = [{
         'url': 'https://cdn.viqeo.tv/embed/?vid=cde96f09d25f39bee837',
         'md5': 'a169dd1a6426b350dca4296226f21e76',
@@ -38,14 +35,6 @@ class ViqeoIE(InfoExtractor):
         'only_matching': True,
     }]
 
-    @staticmethod
-    def _extract_urls(webpage):
-        return [
-            mobj.group('url')
-            for mobj in re.finditer(
-                r'<iframe[^>]+\bsrc=(["\'])(?P<url>(?:https?:)?//cdn\.viqeo\.tv/embed/*\?.*?\bvid=[\da-f]+.*?)\1',
-                webpage)]
-
     def _real_extract(self, url):
         video_id = self._match_id(url)
 
@@ -86,7 +75,6 @@ def _real_extract(self, url):
                     'vcodec': 'none' if is_audio else None,
                 })
                 formats.append(f)
-        self._sort_formats(formats)
 
         duration = int_or_none(data.get('duration'))