Update pptv.py

fixed pptv video url match
This commit is contained in:
redstoneleo 2016-12-26 20:31:37 +08:00 committed by GitHub
parent af4db738a2
commit e358e33241

View File

@ -143,7 +143,7 @@ def pptv_download_by_id(id, title = None, output_dir = '.', merge = True, info_o
pptv_download_by_id(id, output_dir = output_dir, merge = merge, info_only = info_only)
def pptv_download(url, output_dir = '.', merge = True, info_only = False, **kwargs):
assert re.match(r'http://v.pptv.com/show/(\w+)\.html$', url)
assert re.match(r'http://v.pptv.com/show/.*?\.html.*', url)
html = get_html(url)
id = r1(r'webcfg\s*=\s*{"id":\s*(\d+)', html)
assert id