projects
/
youtube-dl
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
80e59a0
)
[vrt] Detect geo restriction
author
Sergey M․
<dstftw@gmail.com>
Wed, 17 Feb 2016 17:28:41 +0000
(23:28 +0600)
committer
Sergey M․
<dstftw@gmail.com>
Wed, 17 Feb 2016 17:28:41 +0000
(23:28 +0600)
youtube_dl/extractor/vrt.py
patch
|
blob
|
history
diff --git
a/youtube_dl/extractor/vrt.py
b/youtube_dl/extractor/vrt.py
index 522e2bbc862cf6ccb93f96f0d431276023282789..2b6bae89bd2a450c9babe1ea77e299b806b752c1 100644
(file)
--- a/
youtube_dl/extractor/vrt.py
+++ b/
youtube_dl/extractor/vrt.py
@@
-79,6
+79,10
@@
class VRTIE(InfoExtractor):
formats.extend(self._extract_f4m_formats(
'%s/manifest.f4m' % mobj.group('src'),
video_id, f4m_id='hds', fatal=False))
+
+ if not formats and 'data-video-geoblocking="true"' in webpage:
+ self.raise_geo_restricted('This video is only available in Belgium')
+
self._sort_formats(formats)
title = self._og_search_title(webpage)