mirror of
https://github.com/yt-dlp/yt-dlp.git
synced 2025-06-27 08:58:30 +00:00
require
Co-authored-by: bashonly <88596187+bashonly@users.noreply.github.com>
This commit is contained in:
parent
7ca024bc35
commit
46a42c738a
@ -794,11 +794,7 @@ def _real_extract(self, url):
|
||||
{extract_attributes}, 'data-props', {json.loads}))
|
||||
frontend_id = traverse_obj(embedded_data, ('site', 'frontendId', {str_or_none}), default='9')
|
||||
|
||||
if not (ws_url := traverse_obj(embedded_data, (
|
||||
'site', 'relive', 'webSocketUrl', {url_or_none},
|
||||
))):
|
||||
raise ExtractorError('Unable to fetch WebSocket URL', expected=True)
|
||||
|
||||
ws_url = traverse_obj(embedded_data, ('site', 'relive', 'webSocketUrl', {url_or_none}, {require('websocket URL')}))
|
||||
ws_url = update_url_query(ws_url, {'frontend_id': frontend_id})
|
||||
ws = self._request_webpage(
|
||||
ws_url, video_id, 'Connecting to WebSocket server',
|
||||
|
Loading…
Reference in New Issue
Block a user