Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add vk.com authentification options #2206

Closed
spvkgn opened this issue Jan 23, 2014 · 6 comments
Closed

Add vk.com authentification options #2206

spvkgn opened this issue Jan 23, 2014 · 6 comments
Labels

Comments

@spvkgn
Copy link

@spvkgn spvkgn commented Jan 23, 2014

Many videos on vk.com are private and can be watched only when logged in. Would be nice if you could add authentification options for vk.com. I can watch this video in browser when I logged in.

youtube-dl -vg http://vk.com/video-8871596_164049491
[debug] System config: []
[debug] User config: []
[debug] Command-line args: ['-vg', 'http://vk.com/video-8871596_164049491']
[debug] Encodings: locale 'UTF-8', fs 'UTF-8', out 'UTF-8', pref: 'UTF-8'
[debug] youtube-dl version 2014.01.23
[debug] Python version 2.7.3 - Linux-3.2.0-39-generic-i686-with-LinuxMint-13-maya
[debug] Proxy map: {}
ERROR: Unable to extract vars; please report this issue on https://yt-dl.org/bug . Be sure to call youtube-dl with the --verbose flag and include its complete output. Make sure you are using the latest version; type youtube-dl -U to update.
Traceback (most recent call last):
File "/home/pavel/apps/bin/youtube-dl/youtube_dl/YoutubeDL.py", line 497, in extract_info
ie_result = ie.extract(url)
File "/home/pavel/apps/bin/youtube-dl/youtube_dl/extractor/common.py", line 157, in extract
return self._real_extract(url)
File "/home/pavel/apps/bin/youtube-dl/youtube_dl/extractor/vk.py", line 46, in _real_extract
data_json = self._search_regex(r'var vars = ({.*?});', info_page, 'vars')
File "/home/pavel/apps/bin/youtube-dl/youtube_dl/extractor/common.py", line 352, in _search_regex
raise RegexNotFoundError(u'Unable to extract %s' % _name)
RegexNotFoundError: Unable to extract vars; please report this issue on https://yt-dl.org/bug . Be sure to call youtube-dl with the --verbose flag and include its complete output. Make sure you are using the latest version; type youtube-dl -U to update.

@dstftw dstftw closed this in 9032dc2 Feb 16, 2014
@dstftw
Copy link
Collaborator

@dstftw dstftw commented Feb 16, 2014

Thank you for the report. Support for vk.com authentication has been added and will be available in next release of youtube-dl. You'll then be able to use it as follows: youtube-dl -u vk_login -p vk_password -vg http://vk.com/video-8871596_164049491

@phihag
Copy link
Contributor

@phihag phihag commented Feb 17, 2014

Fixed in youtube-dl 2014.02.17. Type youtube-dl -U to update.

@mikaiyl
Copy link

@mikaiyl mikaiyl commented Mar 11, 2014

I am still having trouble with this issue, I have youtube-dl 2014.03.10.

[debug] System config: []
[debug] User config: []
[debug] Command-line args: ['-u', "''", '-p', "''", '-vg', 'http://vk.com/video227603911_167132719?list=f7f72a8cd72acf18ca']
[debug] Encodings: locale 'UTF-8', fs 'UTF-8', out 'UTF-8', pref: 'UTF-8'
[debug] youtube-dl version 2014.03.10
[debug] Python version 2.7.4 - Linux-3.8.0-19-generic-i686-with-Ubuntu-13.04-raring
[debug] Proxy map: {}
[vk.com] Logging in as ""
[vk.com] 227603911_167132719: Downloading webpage
ERROR: Unable to extract vars; please report this issue on https://yt-dl.org/bug . Be sure to call youtube-dl with the --verbose flag and include its complete output. Make sure you are using the latest version; type youtube-dl -U to update.
Traceback (most recent call last):
File "/usr/bin/youtube-dl/youtube_dl/YoutubeDL.py", line 503, in extract_info
ie_result = ie.extract(url)
File "/usr/bin/youtube-dl/youtube_dl/extractor/common.py", line 162, in extract
return self._real_extract(url)
File "/usr/bin/youtube-dl/youtube_dl/extractor/vk.py", line 113, in _real_extract
data_json = self._search_regex(r'var vars = ({.*?});', info_page, 'vars')
File "/usr/bin/youtube-dl/youtube_dl/extractor/common.py", line 360, in _search_regex
raise RegexNotFoundError(u'Unable to extract %s' % _name)
RegexNotFoundError: Unable to extract vars; please report this issue on https://yt-dl.org/bug . Be sure to call youtube-dl with the --verbose flag and include its complete output. Make sure you are using the latest version; type youtube-dl -U to update.

@Tatarigami
Copy link

@Tatarigami Tatarigami commented Dec 3, 2014

it also will be nice to make this option be valid for vk.com only... wrote the pass in conf file and it tries it to vimeo too(

@naglis
Copy link
Collaborator

@naglis naglis commented Dec 11, 2014

@not-your-conscience, if you are running a POSIX operating system it can be achieved by putting vk.com credentials in a .netrc file in your home directory, for example:

machine vk
login <your_username>
password <your_password>

and then running youtube-dl with -n or --netrc flag (or you could put it inside your config file).

Another, less convenient workaround would be to use the --ignore-config flag for sites that are not vk.com, however, this means more typing and you would lose the global options inside your configuration file (if you have any).

Also, next time please feel free to open a new issue regarding your problem, because commenting on already closed issues makes it harder to track individual issues and/or might go unnoticed by us (like is almost happened this time ;)

@spvkgn
Copy link
Author

@spvkgn spvkgn commented Feb 25, 2015

Can you please take a look at this issue with authentication on vk.com ? #4967

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Linked pull requests

Successfully merging a pull request may close this issue.

None yet
6 participants
You can’t perform that action at this time.