From b7da73eb19e00e4eab43ec7de129e9aa12f6d5d3 Mon Sep 17 00:00:00 2001 From: pukkandan Date: Sat, 17 Apr 2021 05:39:58 +0530 Subject: Add option `--ignore-no-formats-error` * Ignores the "no video format" and similar errors * Experimental - Some extractors may still throw these errors --- yt_dlp/extractor/brightcove.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'yt_dlp/extractor/brightcove.py') diff --git a/yt_dlp/extractor/brightcove.py b/yt_dlp/extractor/brightcove.py index 8b29ca993..d2fd10064 100644 --- a/yt_dlp/extractor/brightcove.py +++ b/yt_dlp/extractor/brightcove.py @@ -545,9 +545,9 @@ class BrightcoveNewIE(AdobePassIE): errors = json_data.get('errors') if errors: error = errors[0] - raise ExtractorError( + self.raise_no_formats( error.get('message') or error.get('error_subcode') or error['error_code'], expected=True) - if (not self._downloader.params.get('allow_unplayable_formats') + elif (not self._downloader.params.get('allow_unplayable_formats') and sources and num_drm_sources == len(sources)): raise ExtractorError('This video is DRM protected.', expected=True) -- cgit v1.2.3