aboutsummaryrefslogtreecommitdiffstats
path: root/hypervideo_dl/extractor/washingtonpost.py
diff options
context:
space:
mode:
Diffstat (limited to 'hypervideo_dl/extractor/washingtonpost.py')
-rw-r--r--hypervideo_dl/extractor/washingtonpost.py10
1 files changed, 1 insertions, 9 deletions
diff --git a/hypervideo_dl/extractor/washingtonpost.py b/hypervideo_dl/extractor/washingtonpost.py
index 9d6ae28..74501b1 100644
--- a/hypervideo_dl/extractor/washingtonpost.py
+++ b/hypervideo_dl/extractor/washingtonpost.py
@@ -1,6 +1,3 @@
-# coding: utf-8
-from __future__ import unicode_literals
-
import re
from .common import InfoExtractor
@@ -11,7 +8,7 @@ from ..utils import traverse_obj
class WashingtonPostIE(InfoExtractor):
IE_NAME = 'washingtonpost'
_VALID_URL = r'(?:washingtonpost:|https?://(?:www\.)?washingtonpost\.com/(?:video|posttv)/(?:[^/]+/)*)(?P<id>[\da-f]{8}-[\da-f]{4}-[\da-f]{4}-[\da-f]{4}-[\da-f]{12})'
- _EMBED_URL = r'https?://(?:www\.)?washingtonpost\.com/video/c/embed/[\da-f]{8}-[\da-f]{4}-[\da-f]{4}-[\da-f]{4}-[\da-f]{12}'
+ _EMBED_REGEX = [r'<iframe[^>]+\bsrc=["\'](?P<url>https?://(?:www\.)?washingtonpost\.com/video/c/embed/[\da-f]{8}-[\da-f]{4}-[\da-f]{4}-[\da-f]{4}-[\da-f]{12})']
_TESTS = [{
'url': 'https://www.washingtonpost.com/video/c/video/480ba4ee-1ec7-11e6-82c2-a7dcb313287d',
'md5': '6f537e1334b714eb15f9563bd4b9cdfa',
@@ -31,11 +28,6 @@ class WashingtonPostIE(InfoExtractor):
'only_matching': True,
}]
- @classmethod
- def _extract_urls(cls, webpage):
- return re.findall(
- r'<iframe[^>]+\bsrc=["\'](%s)' % cls._EMBED_URL, webpage)
-
def _real_extract(self, url):
video_id = self._match_id(url)
return self.url_result(