X-Git-Url: http://git.bitcoin.ninja/index.cgi?a=blobdiff_plain;ds=sidebyside;f=youtube_dl%2Fextractor%2Fpolskieradio.py;h=f559b899f44d216d0f59a5e282de0658cbf4af48;hb=9ba1e1dcc0dc27d36f3f396cb608cef7cd50e48a;hp=f5adff08ffd91bc01bffd57be3814e75415d553f;hpb=0463b77a1f83f3f9239c6c5f5d1ca251afd267e4;p=youtube-dl diff --git a/youtube_dl/extractor/polskieradio.py b/youtube_dl/extractor/polskieradio.py index f5adff08f..f559b899f 100644 --- a/youtube_dl/extractor/polskieradio.py +++ b/youtube_dl/extractor/polskieradio.py @@ -33,6 +33,7 @@ class PolskieRadioIE(InfoExtractor): 'timestamp': 1456594200, 'upload_date': '20160227', 'duration': 2364, + 'thumbnail': 're:^https?://static\.prsa\.pl/images/.*\.jpg$' }, }], }, { @@ -49,6 +50,10 @@ class PolskieRadioIE(InfoExtractor): }, { 'url': 'http://www.polskieradio.pl/7/5102/Artykul/1587943', 'only_matching': True, + }, { + # with mp4 video + 'url': 'http://www.polskieradio.pl/9/299/Artykul/1634903,Brexit-Leszek-Miller-swiat-sie-nie-zawali-Europa-bedzie-trwac-dalej', + 'only_matching': True, }] def _real_extract(self, url): @@ -64,6 +69,8 @@ class PolskieRadioIE(InfoExtractor): r'(?s)]+id="datetime2"[^>]*>(.+?)', webpage, 'timestamp', fatal=False)) + thumbnail_url = self._og_search_thumbnail(webpage) + entries = [] media_urls = set() @@ -83,6 +90,7 @@ class PolskieRadioIE(InfoExtractor): 'duration': int_or_none(media.get('length')), 'vcodec': 'none' if media.get('provider') == 'audio' else None, 'timestamp': timestamp, + 'thumbnail': thumbnail_url }) title = self._og_search_title(webpage).strip()