projects
/
youtube-dl
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
[democracynow] Update test
[youtube-dl]
/
youtube_dl
/
extractor
/
pladform.py
diff --git
a/youtube_dl/extractor/pladform.py
b/youtube_dl/extractor/pladform.py
index 551c8c9f0fef4566afd5691628b2c216c157fd0c..e38c7618e4d29177721f21a36479b7cbd3d0cf28 100644
(file)
--- a/
youtube_dl/extractor/pladform.py
+++ b/
youtube_dl/extractor/pladform.py
@@
-1,6
+1,8
@@
# coding: utf-8
from __future__ import unicode_literals
# coding: utf-8
from __future__ import unicode_literals
+import re
+
from .common import InfoExtractor
from ..utils import (
ExtractorError,
from .common import InfoExtractor
from ..utils import (
ExtractorError,
@@
-32,7
+34,7
@@
class PladformIE(InfoExtractor):
'ext': 'mp4',
'title': 'Тайны перевала Дятлова • 1 серия 2 часть',
'description': 'Документальный сериал-расследование одной из самых жутких тайн ХХ века',
'ext': 'mp4',
'title': 'Тайны перевала Дятлова • 1 серия 2 часть',
'description': 'Документальный сериал-расследование одной из самых жутких тайн ХХ века',
- 'thumbnail': 're:^https?://.*\.jpg$',
+ 'thumbnail':
r
're:^https?://.*\.jpg$',
'duration': 694,
'age_limit': 0,
},
'duration': 694,
'age_limit': 0,
},
@@
-44,6
+46,13
@@
class PladformIE(InfoExtractor):
'only_matching': True,
}]
'only_matching': True,
}]
+ @staticmethod
+ def _extract_url(webpage):
+ mobj = re.search(
+ r'<iframe[^>]+src=(["\'])(?P<url>(?:https?:)?//out\.pladform\.ru/player\?.+?)\1', webpage)
+ if mobj:
+ return mobj.group('url')
+
def _real_extract(self, url):
video_id = self._match_id(url)
def _real_extract(self, url):
video_id = self._match_id(url)