]>
jfr.im git - yt-dlp.git/blob - yt_dlp/extractor/lenta.py
1 from .common
import InfoExtractor
4 class LentaIE(InfoExtractor
):
5 _VALID_URL
= r
'https?://(?:www\.)?lenta\.ru/[^/]+/\d+/\d+/\d+/(?P<id>[^/?#&]+)'
7 'url': 'https://lenta.ru/news/2018/03/22/savshenko_go/',
11 'title': 'Надежду Савченко задержали',
12 'thumbnail': r
're:^https?://.*\.jpg$',
17 'skip_download': True,
20 # EaglePlatform iframe embed
21 'url': 'http://lenta.ru/news/2015/03/06/navalny/',
25 'title': 'Навальный вышел на свободу',
26 'description': 'md5:d97861ac9ae77377f3f20eaf9d04b4f5',
27 'thumbnail': r
're:^https?://.*\.jpg$',
33 'skip_download': True,
37 def _real_extract(self
, url
):
38 display_id
= self
._match
_id
(url
)
40 webpage
= self
._download
_webpage
(url
, display_id
)
42 video_id
= self
._search
_regex
(
43 r
'vid\s*:\s*["\']?
(\d
+)', webpage, 'eagleplatform
id',
46 return self.url_result(
47 'eagleplatform
:lentaru
.media
.eagleplatform
.com
:%s' % video_id,
48 ie='EaglePlatform
', video_id=video_id)
50 return self.url_result(url, ie='Generic
')