aboutsummaryrefslogtreecommitdiff
path: root/youtube_dl
diff options
context:
space:
mode:
authorYen Chi Hsuan <yan12125@gmail.com>2016-04-14 14:11:28 +0800
committerYen Chi Hsuan <yan12125@gmail.com>2016-04-14 14:11:28 +0800
commitd1c4e4ba150562fcf7aedef26646dff7425ccd73 (patch)
tree41b7b86a1d3a418900f5c012a34bb28f7feed92e /youtube_dl
parentf141fefab73d96a6dd2c927f56d0b86253991c02 (diff)
[laola1tv] Improve error detection and skip an invalid test
Diffstat (limited to 'youtube_dl')
-rw-r--r--youtube_dl/extractor/laola1tv.py4
1 files changed, 4 insertions, 0 deletions
diff --git a/youtube_dl/extractor/laola1tv.py b/youtube_dl/extractor/laola1tv.py
index d4fbafece..2fab38079 100644
--- a/youtube_dl/extractor/laola1tv.py
+++ b/youtube_dl/extractor/laola1tv.py
@@ -63,6 +63,7 @@ class Laola1TvIE(InfoExtractor):
'params': {
'skip_download': True,
},
+ 'skip': 'This live stream has already finished.',
}]
def _real_extract(self, url):
@@ -74,6 +75,9 @@ class Laola1TvIE(InfoExtractor):
webpage = self._download_webpage(url, display_id)
+ if 'Dieser Livestream ist bereits beendet.' in webpage:
+ raise ExtractorError('This live stream has already finished.', expected=True)
+
iframe_url = self._search_regex(
r'<iframe[^>]*?id="videoplayer"[^>]*?src="([^"]+)"',
webpage, 'iframe url')