Join GitHub today
GitHub is home to over 50 million developers working together to host and review code, manage projects, and build software together.
Sign upGitHub is where the world builds software
Millions of developers and companies build, ship, and maintain their software on GitHub — the largest and most advanced development platform in the world.
Vidzi is broken #6819
Vidzi is broken #6819
Comments
|
Body of webpage: https://gist.github.com/davek-cygwin/9ba2d360d963dbc0495f Relevant part is: <script type="text/javascript" src="http://static.vidzi.tv/nplayer/jwplayer.js"></script>
</script>
This decodes to: jwplayer("vplayer").setup({playlist:[{image:"http://77.81.98.155:8777/i/01/00048/jnk3om3hftz4.jpg",provider:"http://static.vidzi.tv/nplayer/vidzi.swf",sources:[{file:"http://vidzi.tv/jnk3om3hftz4-c4d4eb72532019084b9e8b42c1d68f0a.m3u8?embed=",type:'hls'},{file:"http://77.81.98.155:8777/bfuqidr73y2qedz7nktr5ejkl4pzadqtgjicmgo6lvaoqjl3evsehut3zdva/v.mp4"}],tracks:[{file:"http://vidzi.tv/srt/00048/jnk3om3hftz4_Croatian.srt",label:"Croatian",kind:"subtitles"},{file:"http://vidzi.tv/jnk3om3hftz4-c4d4eb72532019084b9e8b42c1d68f0a.vtt",kind:"thumbnails"}]}],height:360,primary:"flash",hls_minbufferlength:3,androidhls:true,hls_startfromlevel:1,hls_maxbufferlength:300,hls_maxbackbufferlength:900,captions:{back:false,color:'FFFFFF',fontFamily:'Verdana',fontsize:20},width:640});var vvplay;var tt242296=0;var p0242296=0;jwplayer().onTime(function(x){if(p0242296>0)tt242296+=x.position-p0242296;p0242296=x.position;if(0!=0&&tt242296>=0){p0242296=-1;jwplayer().stop();jwplayer().setFullscreen(false);$('#play_limit_box').show();$('div.video_ad').show()}});jwplayer().onSeek(function(x){p0242296=-1});jwplayer().onPlay(function(x){doPlay(x)});jwplayer().onComplete(function(){$('div.video_ad').show()});function doPlay(x){$('div.video_ad').hide();if(vvplay)return;vvplay=1;$.get('http://vidzi.tv/cgi-bin/index_dl.cgi?op=ajax&file_code=jnk3om3hftz4&hash=242296-85-210-1441844182-7ce405bc990115957951f5a3aad0f2e7',function(data){})} |
|
this can be fixed temporaly by adding this code to vidzi.py: def unpack_packer(p, a, c, k, s):
k = k.split(s)
import gmpy2
for i in range(int(c) - 1, 1, -1):
p = re.sub('\\b' + gmpy2.digits(i, int(a)) + '\\b', k[i], p)
return p
def unpack(content):
packers = re.findall(r'function\(p,a,c,k,e,d\){.+}\(\'.*\',\d+,\d+,\'[^\']+\'\.split\(\'.\'\)', content)
for (packer) in packers:
p, a, c, k, s = re.search(r'function\(p,a,c,k,e,d\){.+}\(\'(.*)\',(\d+),(\d+),\'([^\']+)\'\.split\(\'(.)\'\)', packer).groups()
content = content.replace(packer, unpack_packer(p, a, c, k, s))
return content
webpage = unpack(webpage)after this line: webpage = self._download_webpage(url, video_id)it requires to install gmpy2.
|
|
@remitamine Thanks for proposing a solution. I guess |
there are a lot of solution but i don't know what code will be accepted to add to youtube-dl because i didn't find a code with the same licence(as i know you accept only code from projects licenced under the public domain) for windows, gmpy2 can be downloaded from here: |
|
Thanks for the report and all that provide ideas. Vidzi will work again in the next version. |
C:\Projects\rg3\youtube-dl>python -m youtube_dl "http://vidzi.tv/jnk3om3hftz4.html" --verbose 2>&1 | tee fail-vidzi.log
[debug] System config: []
[debug] User config: []
[debug] Command-line args: [u'http://vidzi.tv/jnk3om3hftz4.html', u'--verbose']
[debug] Encodings: locale cp1252, fs mbcs, out None, pref cp1252
[debug] youtube-dl version 2015.09.09
[debug] Git HEAD: 1721fef
[debug] Python version 2.7.8 - Windows-7-6.1.7601-SP1
[debug] exe versions: ffmpeg 0.8.1, rtmpdump 2.4
[debug] Proxy map: {}
[Vidzi] jnk3om3hftz4: Downloading webpage
ERROR: Unable to extract video url; please report this issue on https://yt-dl.org/bug . Make sure you are using the latest version; see https://yt-dl.org/update on how to update. Be sure to call youtube-dl with the --verbose flag and include its complete output.
Traceback (most recent call last):
File "youtube_dl\YoutubeDL.py", line 660, in extract_info
ie_result = ie.extract(url)
File "youtube_dl\extractor\common.py", line 287, in extract
return self.real_extract(url)
File "youtube_dl\extractor\vidzi.py", line 24, in real_extract
r'{\s_file\s:\s"([^"]+)"\s_}', webpage, 'video url')
File "youtube_dl\extractor\common.py", line 584, in _html_search_regex
res = self._search_regex(pattern, string, name, default, fatal, flags, group)
File "youtube_dl\extractor\common.py", line 575, in _search_regex
raise RegexNotFoundError('Unable to extract %s' % _name)
RegexNotFoundError: Unable to extract video url; please report this issue on https://yt-dl.org/bug . Make sure you are using the latest version; see https://yt-dl.org/update on how to update. Be sure to call youtube-dl with the --verbose flag and include its complete output.