From 9612f2339909f958f0c7ee7ccc370151ec28358d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergey=20M=E2=80=A4?= Date: Tue, 22 Sep 2015 21:54:32 +0600 Subject: [PATCH] [viewster] Detect video geo restriction --- youtube_dl/extractor/viewster.py | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/youtube_dl/extractor/viewster.py b/youtube_dl/extractor/viewster.py index f8f4143c6..7c4328efb 100644 --- a/youtube_dl/extractor/viewster.py +++ b/youtube_dl/extractor/viewster.py @@ -140,6 +140,10 @@ class ViewsterIE(InfoExtractor): f['height'] = int_or_none(self._search_regex( r'^(\d+)[pP]$', format_id, 'height', default=None)) formats.append(f) + + if not formats and not info.get('LanguageSets') and not info.get('VODSettings'): + self.raise_geo_restricted() + self._sort_formats(formats) synopsis = info.get('Synopsis', {})