mirror of
https://github.com/blackjack4494/yt-dlc.git
synced 2024-12-26 17:58:09 +00:00
[extractor/generic] Improve kaltura embeds support (Closes #6137)
This commit is contained in:
parent
f5ca97e393
commit
66e568de3b
1 changed files with 14 additions and 2 deletions
|
@ -669,6 +669,18 @@ class GenericIE(InfoExtractor):
|
||||||
'title': 'John Carlson Postgame 2/25/15',
|
'title': 'John Carlson Postgame 2/25/15',
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
|
# Kaltura embed (different embed code)
|
||||||
|
{
|
||||||
|
'url': 'http://www.premierchristianradio.com/Shows/Saturday/Unbelievable/Conference-Videos/Os-Guinness-Is-It-Fools-Talk-Unbelievable-Conference-2014',
|
||||||
|
'info_dict': {
|
||||||
|
'id': '1_a52wc67y',
|
||||||
|
'ext': 'flv',
|
||||||
|
'upload_date': '20150127',
|
||||||
|
'uploader_id': 'PremierMedia',
|
||||||
|
'timestamp': int,
|
||||||
|
'title': 'Os Guinness // Is It Fools Talk? // Unbelievable? Conference 2014',
|
||||||
|
},
|
||||||
|
},
|
||||||
# Eagle.Platform embed (generic URL)
|
# Eagle.Platform embed (generic URL)
|
||||||
{
|
{
|
||||||
'url': 'http://lenta.ru/news/2015/03/06/navalny/',
|
'url': 'http://lenta.ru/news/2015/03/06/navalny/',
|
||||||
|
@ -1492,8 +1504,8 @@ class GenericIE(InfoExtractor):
|
||||||
return self.url_result(mobj.group('url'), 'Zapiks')
|
return self.url_result(mobj.group('url'), 'Zapiks')
|
||||||
|
|
||||||
# Look for Kaltura embeds
|
# Look for Kaltura embeds
|
||||||
mobj = re.search(
|
mobj = (re.search(r"(?s)kWidget\.(?:thumb)?[Ee]mbed\(\{.*?'wid'\s*:\s*'_?(?P<partner_id>[^']+)',.*?'entry_id'\s*:\s*'(?P<id>[^']+)',", webpage) or
|
||||||
r"(?s)kWidget\.(?:thumb)?[Ee]mbed\(\{.*?'wid'\s*:\s*'_?(?P<partner_id>[^']+)',.*?'entry_id'\s*:\s*'(?P<id>[^']+)',", webpage)
|
re.search(r'(?s)(["\'])(?:https?:)?//cdnapisec\.kaltura\.com/.*?(?:p|partner_id)/(?P<partner_id>\d+).*?\1.*?entry_id\s*:\s*(["\'])(?P<id>[^\2]+?)\2', webpage))
|
||||||
if mobj is not None:
|
if mobj is not None:
|
||||||
return self.url_result('kaltura:%(partner_id)s:%(id)s' % mobj.groupdict(), 'Kaltura')
|
return self.url_result('kaltura:%(partner_id)s:%(id)s' % mobj.groupdict(), 'Kaltura')
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue