mirror of
https://codeberg.org/polarisfm/youtube-dl
synced 2024-11-23 00:54:31 +01:00
[yahoo] Add test and improve some content id regex
This commit is contained in:
parent
f420902a3b
commit
b61cd51869
@ -201,6 +201,19 @@ class YahooIE(InfoExtractor):
|
|||||||
},
|
},
|
||||||
'skip': 'redirect to https://www.yahoo.com/music',
|
'skip': 'redirect to https://www.yahoo.com/music',
|
||||||
},
|
},
|
||||||
|
{
|
||||||
|
# yahoo://article/
|
||||||
|
'url': 'https://www.yahoo.com/movies/video/true-story-trailer-173000497.html',
|
||||||
|
'info_dict': {
|
||||||
|
'id': '071c4013-ce30-3a93-a5b2-e0413cd4a9d1',
|
||||||
|
'ext': 'mp4',
|
||||||
|
'title': "'True Story' Trailer",
|
||||||
|
'description': 'True Story',
|
||||||
|
},
|
||||||
|
'params': {
|
||||||
|
'skip_download': True,
|
||||||
|
},
|
||||||
|
},
|
||||||
{
|
{
|
||||||
# ytwnews://cavideo/
|
# ytwnews://cavideo/
|
||||||
'url': 'https://tw.video.yahoo.com/movie-tw/單車天使-中文版預-092316541.html',
|
'url': 'https://tw.video.yahoo.com/movie-tw/單車天使-中文版預-092316541.html',
|
||||||
@ -282,7 +295,7 @@ class YahooIE(InfoExtractor):
|
|||||||
r'"first_videoid"\s*:\s*"([^"]+)"',
|
r'"first_videoid"\s*:\s*"([^"]+)"',
|
||||||
r'%s[^}]*"ccm_id"\s*:\s*"([^"]+)"' % re.escape(page_id),
|
r'%s[^}]*"ccm_id"\s*:\s*"([^"]+)"' % re.escape(page_id),
|
||||||
r'<article[^>]data-uuid=["\']([^"\']+)',
|
r'<article[^>]data-uuid=["\']([^"\']+)',
|
||||||
r'yahoo://article/view\?.*\buuid=([^&"\']+)',
|
r'<meta[^<>]+yahoo://article/view\?.*\buuid=([^&"\']+)',
|
||||||
r'<meta[^<>]+["\']ytwnews://cavideo/(?:[^/]+/)+([\da-fA-F-]+)[&"\']',
|
r'<meta[^<>]+["\']ytwnews://cavideo/(?:[^/]+/)+([\da-fA-F-]+)[&"\']',
|
||||||
]
|
]
|
||||||
video_id = self._search_regex(
|
video_id = self._search_regex(
|
||||||
|
Loading…
Reference in New Issue
Block a user