Compare commits

...

4 Commits

Author SHA1 Message Date
Nathan Touzé
475732caba
Merge efb4d64d2c into 4b5eec0aaa 2024-11-25 08:30:49 +05:30
Jakob Kruse
4b5eec0aaa
[ie/chaturbate] Fix support for non-public streams (#11624)
Fix bug in 720b3dc453

Closes #11623
Authored by: jkruse
2024-11-24 22:20:30 +00:00
Nathan Touzé
efb4d64d2c
removed trailing space 2023-08-22 16:07:02 +02:00
Nathan Touzé
db53c235f2
Applied issue #6744 on vimeo extractor 2023-08-22 14:17:47 +02:00
2 changed files with 10 additions and 11 deletions

View File

@ -59,16 +59,15 @@ def _extract_from_api(self, video_id, tld):
'Accept': 'application/json',
}, fatal=False, impersonate=True) or {}
status = response.get('room_status')
if status != 'public':
if error := self._ERROR_MAP.get(status):
raise ExtractorError(error, expected=True)
self.report_warning('Falling back to webpage extraction')
return None
m3u8_url = response.get('url')
if not m3u8_url:
self.raise_geo_restricted()
status = response.get('room_status')
if error := self._ERROR_MAP.get(status):
raise ExtractorError(error, expected=True)
if status == 'public':
self.raise_geo_restricted()
self.report_warning(f'Got status "{status}" from API; falling back to webpage extraction')
return None
return {
'id': video_id,

View File

@ -336,12 +336,12 @@ class VimeoIE(VimeoBaseInfoExtractor):
play_redirect_hls|
moogaloop\.swf)\?clip_id=
)?
(?:videos?/)?
)
(?(q)|videos?/)?)
(?P<id>[0-9]+)
(?(u)
/(?!videos|likes)[^/?#]+/?|
(?(q)|/(?P<unlisted_hash>[\da-f]{10}))?
(?(q)|/(?P<unlisted_hash>[\da-f]{10})?)?
(?(unlisted_hash)/?)
)
(?:(?(q)[&]|(?(u)|/?)[?]).*?)?(?:[#].*)?$
'''