X-Git-Url: https://git.rapsys.eu/youtubedl/blobdiff_plain/453698570f26bebd37b39df8537d993b57d77b8b..a6abd8dc822fb70852437ab5a77ced5f633739f8:/youtube_dl/extractor/nerdist.py?ds=inline diff --git a/youtube_dl/extractor/nerdist.py b/youtube_dl/extractor/nerdist.py new file mode 100644 index 0000000..c6dc34b --- /dev/null +++ b/youtube_dl/extractor/nerdist.py @@ -0,0 +1,80 @@ +# encoding: utf-8 +from __future__ import unicode_literals + +from .common import InfoExtractor + +from ..utils import ( + determine_ext, + parse_iso8601, + xpath_text, +) + + +class NerdistIE(InfoExtractor): + _VALID_URL = r'https?://(?:www\.)?nerdist\.com/vepisode/(?P[^/?#]+)' + _TEST = { + 'url': 'http://www.nerdist.com/vepisode/exclusive-which-dc-characters-w', + 'md5': '3698ed582931b90d9e81e02e26e89f23', + 'info_dict': { + 'display_id': 'exclusive-which-dc-characters-w', + 'id': 'RPHpvJyr', + 'ext': 'mp4', + 'title': 'Your TEEN TITANS Revealed! Who\'s on the show?', + 'thumbnail': 're:^https?://.*/thumbs/.*\.jpg$', + 'description': 'Exclusive: Find out which DC Comics superheroes will star in TEEN TITANS Live-Action TV Show on Nerdist News with Jessica Chobot!', + 'uploader': 'Eric Diaz', + 'upload_date': '20150202', + 'timestamp': 1422892808, + } + } + + def _real_extract(self, url): + display_id = self._match_id(url) + webpage = self._download_webpage(url, display_id) + + video_id = self._search_regex( + r'''(?x)