diff options
author | Sergey M․ <dstftw@gmail.com> | 2018-02-17 20:11:06 +0700 |
---|---|---|
committer | Sergey M․ <dstftw@gmail.com> | 2018-02-17 20:32:20 +0700 |
commit | b8adcec4eac2fb8946547b581a6e7139171dc9d1 (patch) | |
tree | a2d8442f62c1ec463526935d07732c29df6cf813 /youtube_dl/extractor | |
parent | 073cca3df8595be52463be9f3da81f1f2b736e9c (diff) |
[npo] Capture and output error message
Diffstat (limited to 'youtube_dl/extractor')
-rw-r--r-- | youtube_dl/extractor/npo.py | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/youtube_dl/extractor/npo.py b/youtube_dl/extractor/npo.py index b8fe24407..754a97443 100644 --- a/youtube_dl/extractor/npo.py +++ b/youtube_dl/extractor/npo.py @@ -170,6 +170,10 @@ class NPOIE(NPOBaseIE): transform_source=strip_jsonp, ) + error = metadata.get('error') + if error: + raise ExtractorError(error, expected=True) + # For some videos actual video id (prid) is different (e.g. for # http://www.omroepwnl.nl/video/fragment/vandaag-de-dag-verkiezingen__POMS_WNL_853698 # video id is POMS_WNL_853698 but prid is POW_00996502) |