1
0
Fork 0
mirror of https://github.com/ytdl-org/youtube-dl.git synced 2024-11-18 08:16:10 +00:00

Update youtube_dl/extractor/tvp.py

Co-authored-by: dirkf <fieldhouse@gmx.net>
This commit is contained in:
bibiak 2023-05-22 21:22:01 +02:00 committed by GitHub
parent 578c53381b
commit da19699ff8
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -116,7 +116,12 @@ if not hasattr(InfoExtractor, '_match_valid_url'):
# return self._parse_json(json_string, video_id, ignore_extra=True, **kwargs)
return self._parse_json(json_string, video_id, **kwargs)
except ExtractorError as e:
msg = 'Unable to extract {0} - Failed to parse JSON'.format(name)
except ExtractorError as e:
if not self._downloader.params.get('no_color') and compat_os_name != 'nt' and sys.stderr.isatty():
_name = '\033[0;34m%s\033[0m' % name
else:
_name = name
msg = 'Unable to extract {0} - Failed to parse JSON'.format(_name)
if fatal:
raise ExtractorError(msg, cause=e.cause, video_id=video_id)
elif not has_default: