Compare commits
5 Commits
2015.02.24
...
2015.02.24
Author | SHA1 | Date | |
---|---|---|---|
4f3b21e1c7 | |||
54233c9080 | |||
db8e13ef71 | |||
5a42414b9c | |||
9c665ab72e |
@ -85,6 +85,8 @@ class TestUtil(unittest.TestCase):
|
|||||||
self.assertEqual(
|
self.assertEqual(
|
||||||
sanitize_filename('New World record at 0:12:34'),
|
sanitize_filename('New World record at 0:12:34'),
|
||||||
'New World record at 0_12_34')
|
'New World record at 0_12_34')
|
||||||
|
self.assertEqual(sanitize_filename('--gasdgf'), '_-gasdgf')
|
||||||
|
self.assertEqual(sanitize_filename('--gasdgf', is_id=True), '--gasdgf')
|
||||||
|
|
||||||
forbidden = '"\0\\/'
|
forbidden = '"\0\\/'
|
||||||
for fc in forbidden:
|
for fc in forbidden:
|
||||||
|
@ -42,7 +42,14 @@ class EscapistIE(InfoExtractor):
|
|||||||
title = raw_title.partition(' : ')[2]
|
title = raw_title.partition(' : ')[2]
|
||||||
|
|
||||||
config_url = compat_urllib_parse.unquote(self._html_search_regex(
|
config_url = compat_urllib_parse.unquote(self._html_search_regex(
|
||||||
r'<param\s+name="flashvars"\s+value="config=([^"&]+)', webpage, 'config URL'))
|
r'''(?x)
|
||||||
|
(?:
|
||||||
|
<param\s+name="flashvars"\s+value="config=|
|
||||||
|
flashvars="config=
|
||||||
|
)
|
||||||
|
([^"&]+)
|
||||||
|
''',
|
||||||
|
webpage, 'config URL'))
|
||||||
|
|
||||||
formats = []
|
formats = []
|
||||||
|
|
||||||
|
@ -119,7 +119,8 @@ class RTVEALaCartaIE(InfoExtractor):
|
|||||||
subs = self._download_json(
|
subs = self._download_json(
|
||||||
sub_file + '.json', video_id,
|
sub_file + '.json', video_id,
|
||||||
'Downloading subtitles info')['page']['items']
|
'Downloading subtitles info')['page']['items']
|
||||||
return dict((s['lang'], [{'ext': 'vtt', 'url': s['src']}])
|
return dict(
|
||||||
|
(s['lang'], [{'ext': 'vtt', 'url': s['src']}])
|
||||||
for s in subs)
|
for s in subs)
|
||||||
|
|
||||||
|
|
||||||
|
@ -304,6 +304,8 @@ def sanitize_filename(s, restricted=False, is_id=False):
|
|||||||
# Common case of "Foreign band name - English song title"
|
# Common case of "Foreign band name - English song title"
|
||||||
if restricted and result.startswith('-_'):
|
if restricted and result.startswith('-_'):
|
||||||
result = result[2:]
|
result = result[2:]
|
||||||
|
if result.startswith('-'):
|
||||||
|
result = '_' + result[len('-'):]
|
||||||
if not result:
|
if not result:
|
||||||
result = '_'
|
result = '_'
|
||||||
return result
|
return result
|
||||||
|
@ -1,3 +1,3 @@
|
|||||||
from __future__ import unicode_literals
|
from __future__ import unicode_literals
|
||||||
|
|
||||||
__version__ = '2015.02.24'
|
__version__ = '2015.02.24.2'
|
||||||
|
Reference in New Issue
Block a user