projects
/
youtube-dl
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
|
inline
| side by side (parent:
a122e70
)
[bbc] Extend vpid regex (Closes #9003)
author
Sergey M․
<dstftw@gmail.com>
Sun, 27 Mar 2016 17:22:51 +0000
(23:22 +0600)
committer
Sergey M․
<dstftw@gmail.com>
Sun, 27 Mar 2016 17:22:51 +0000
(23:22 +0600)
youtube_dl/extractor/bbc.py
patch
|
blob
|
history
diff --git
a/youtube_dl/extractor/bbc.py
b/youtube_dl/extractor/bbc.py
index 2dfcee98d5b5ac9e01c611878ad9b073436983df..dedf721bde2724cb7f5a06186584069b3f5221a1 100644
(file)
--- a/
youtube_dl/extractor/bbc.py
+++ b/
youtube_dl/extractor/bbc.py
@@
-688,6
+688,10
@@
class BBCIE(BBCCoUkIE):
# custom redirection to www.bbc.com
'url': 'http://www.bbc.co.uk/news/science-environment-33661876',
'only_matching': True,
# custom redirection to www.bbc.com
'url': 'http://www.bbc.co.uk/news/science-environment-33661876',
'only_matching': True,
+ }, {
+ # single video article embedded with data-media-vpid
+ 'url': 'http://www.bbc.co.uk/sport/rowing/35908187',
+ 'only_matching': True,
}]
@classmethod
}]
@classmethod
@@
-817,7
+821,7
@@
class BBCIE(BBCCoUkIE):
# single video story (e.g. http://www.bbc.com/travel/story/20150625-sri-lankas-spicy-secret)
programme_id = self._search_regex(
# single video story (e.g. http://www.bbc.com/travel/story/20150625-sri-lankas-spicy-secret)
programme_id = self._search_regex(
- [r'data-
video-player
-vpid="(%s)"' % self._ID_REGEX,
+ [r'data-
(?:video-player|media)
-vpid="(%s)"' % self._ID_REGEX,
r'<param[^>]+name="externalIdentifier"[^>]+value="(%s)"' % self._ID_REGEX,
r'videoId\s*:\s*["\'](%s)["\']' % self._ID_REGEX],
webpage, 'vpid', default=None)
r'<param[^>]+name="externalIdentifier"[^>]+value="(%s)"' % self._ID_REGEX,
r'videoId\s*:\s*["\'](%s)["\']' % self._ID_REGEX],
webpage, 'vpid', default=None)