mirror of
https://codeberg.org/polarisfm/youtube-dl.git
synced 2024-12-27 01:56:52 +00:00
[culturebox] Check for unavailable videos
This commit is contained in:
parent
ed676e8c0a
commit
184a197441
1 changed files with 5 additions and 0 deletions
|
@ -275,7 +275,12 @@ class CultureboxIE(FranceTVBaseInfoExtractor):
|
||||||
def _real_extract(self, url):
|
def _real_extract(self, url):
|
||||||
mobj = re.match(self._VALID_URL, url)
|
mobj = re.match(self._VALID_URL, url)
|
||||||
name = mobj.group('name')
|
name = mobj.group('name')
|
||||||
|
|
||||||
webpage = self._download_webpage(url, name)
|
webpage = self._download_webpage(url, name)
|
||||||
|
|
||||||
|
if ">Ce live n'est plus disponible en replay<" in webpage:
|
||||||
|
raise ExtractorError('Video %s is not available' % name, expected=True)
|
||||||
|
|
||||||
video_id, catalogue = self._search_regex(
|
video_id, catalogue = self._search_regex(
|
||||||
r'"http://videos\.francetv\.fr/video/([^@]+@[^"]+)"', webpage, 'video id').split('@')
|
r'"http://videos\.francetv\.fr/video/([^@]+@[^"]+)"', webpage, 'video id').split('@')
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue