[Youtube] Make n-sig throttling diagnostic up-to-date
This commit is contained in:
parent
16f5bbc464
commit
451046d62a
@ -1647,7 +1647,7 @@ class YoutubeIE(YoutubeBaseInfoExtractor):
|
|||||||
except JSInterpreter.Exception as e:
|
except JSInterpreter.Exception as e:
|
||||||
self.report_warning(
|
self.report_warning(
|
||||||
'%s (%s %s)' % (
|
'%s (%s %s)' % (
|
||||||
'Unable to decode n-parameter: download likely to be throttled',
|
'Unable to decode n-parameter: expect download to be blocked or throttled',
|
||||||
error_to_compat_str(e),
|
error_to_compat_str(e),
|
||||||
traceback.format_exc()),
|
traceback.format_exc()),
|
||||||
video_id=video_id)
|
video_id=video_id)
|
||||||
@ -1670,7 +1670,7 @@ class YoutubeIE(YoutubeBaseInfoExtractor):
|
|||||||
return func_name
|
return func_name
|
||||||
|
|
||||||
return self._parse_json(self._search_regex(
|
return self._parse_json(self._search_regex(
|
||||||
r'var {0}\s*=\s*(\[.+?\])\s*[,;]'.format(re.escape(func_name)), jscode,
|
r'var\s+{0}\s*=\s*(\[.+?\])\s*[,;]'.format(re.escape(func_name)), jscode,
|
||||||
'Initial JS player n function list ({0}.{1})'.format(func_name, idx)),
|
'Initial JS player n function list ({0}.{1})'.format(func_name, idx)),
|
||||||
func_name, transform_source=js_to_json)[int(idx)]
|
func_name, transform_source=js_to_json)[int(idx)]
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user