mirror of
https://github.com/yt-dlp/yt-dlp.git
synced 2024-08-16 20:31:05 +02:00
[rai] Support an alternative form of embedded relinker URL
Closes #8551
This commit is contained in:
parent
2b28b892d8
commit
15e4b6b758
@ -221,6 +221,15 @@ class RaiIE(RaiBaseIE):
|
|||||||
'upload_date': '20160702',
|
'upload_date': '20160702',
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
|
{
|
||||||
|
'url': 'http://www.rainews.it/dl/rainews/live/ContentItem-3156f2f2-dc70-4953-8e2f-70d7489d4ce9.html',
|
||||||
|
# HDS live stream, MD5 is unstable
|
||||||
|
'info_dict': {
|
||||||
|
'id': '3156f2f2-dc70-4953-8e2f-70d7489d4ce9',
|
||||||
|
'ext': 'flv',
|
||||||
|
'title': 'La diretta di Rainews24',
|
||||||
|
},
|
||||||
|
},
|
||||||
]
|
]
|
||||||
|
|
||||||
@classmethod
|
@classmethod
|
||||||
@ -247,7 +256,7 @@ def _real_extract(self, url):
|
|||||||
return self._extract_from_content_id(content_item_id, url)
|
return self._extract_from_content_id(content_item_id, url)
|
||||||
|
|
||||||
relinker_url = compat_urlparse.urljoin(url, self._search_regex(
|
relinker_url = compat_urlparse.urljoin(url, self._search_regex(
|
||||||
r'var\s+videoURL\s*=\s*(?P<q1>[\'"])(?P<url>(https?:)?//mediapolis\.rai\.it/relinker/relinkerServlet\.htm\?cont=\d+)(?P=q1)',
|
r'(?:var\s+videoURL|mediaInfo\.mediaUri)\s*=\s*(?P<q1>[\'"])(?P<url>(https?:)?//mediapolis\.rai\.it/relinker/relinkerServlet\.htm\?cont=\d+)(?P=q1)',
|
||||||
webpage, 'relinker URL', group='url'))
|
webpage, 'relinker URL', group='url'))
|
||||||
formats = self._extract_relinker_formats(relinker_url, video_id)
|
formats = self._extract_relinker_formats(relinker_url, video_id)
|
||||||
self._sort_formats(formats)
|
self._sort_formats(formats)
|
||||||
|
Loading…
Reference in New Issue
Block a user