1
0
mirror of https://github.com/ytdl-org/youtube-dl synced 2024-12-21 08:56:52 +00:00

[niconico] improve error reporting (#13696)

This commit is contained in:
Yen Chi Hsuan 2017-07-23 16:25:17 +08:00
parent 73095e013f
commit e3ce912c3d
No known key found for this signature in database
GPG Key ID: 7F902A182457CA23

View File

@ -147,6 +147,9 @@ class NiconicoIE(InfoExtractor):
elif 'closed' in flv_info:
raise ExtractorError('Niconico videos now require logging in',
expected=True)
elif 'error' in flv_info:
raise ExtractorError('%s reports error: %s' % (
self.IE_NAME, flv_info['error'][0]), expected=True)
else:
raise ExtractorError('Unable to find video URL')