mirror of
https://github.com/ytdl-org/youtube-dl.git
synced 2024-11-29 21:52:54 +00:00
[shahid] raise ExtractorError instead of warning
This commit is contained in:
parent
114ed20e64
commit
02c126a7c2
1 changed files with 5 additions and 2 deletions
|
@ -1,5 +1,8 @@
|
||||||
from .common import InfoExtractor
|
from .common import InfoExtractor
|
||||||
from ..utils import get_element_by_id
|
from ..utils import (
|
||||||
|
get_element_by_id,
|
||||||
|
ExtractorError,
|
||||||
|
}
|
||||||
|
|
||||||
class ShahidIE(InfoExtractor):
|
class ShahidIE(InfoExtractor):
|
||||||
_VALID_URL = r'https?://shahid\.mbc\.net/ar/episode/(?P<id>\d+)/?'
|
_VALID_URL = r'https?://shahid\.mbc\.net/ar/episode/(?P<id>\d+)/?'
|
||||||
|
@ -43,7 +46,7 @@ class ShahidIE(InfoExtractor):
|
||||||
m3u8_url = player_json_data['url']
|
m3u8_url = player_json_data['url']
|
||||||
else:
|
else:
|
||||||
for error in json_data['error'].values():
|
for error in json_data['error'].values():
|
||||||
self.report_warning(error)
|
raise ExtractorError(error)
|
||||||
return
|
return
|
||||||
formats = self._extract_m3u8_formats(m3u8_url, video_id)
|
formats = self._extract_m3u8_formats(m3u8_url, video_id)
|
||||||
return {
|
return {
|
||||||
|
|
Loading…
Reference in a new issue