[youtube] Make invalid storyboard URL non-fatal

Closes #2382
This commit is contained in:
pukkandan 2022-01-19 18:09:52 +05:30
parent b6ce9bb038
commit 596379e260
No known key found for this signature in database
GPG key ID: 0F00D95A001F4698

View file

@ -3058,9 +3058,9 @@ def process_manifest_format(f, proto, itag):
def _extract_storyboard(self, player_responses, duration):
spec = get_first(
player_responses, ('storyboards', 'playerStoryboardSpecRenderer', 'spec'), default='').split('|')[::-1]
if not spec:
base_url = url_or_none(urljoin('https://i.ytimg.com/', spec.pop() or None))
if not base_url:
return
base_url = spec.pop()
L = len(spec) - 1
for i, args in enumerate(spec):
args = args.split('#')