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

HTTP Error 402: Payment Required #1337

Closed
pimenta opened this issue Aug 28, 2013 · 10 comments
Closed

HTTP Error 402: Payment Required #1337

pimenta opened this issue Aug 28, 2013 · 10 comments

Comments

@pimenta
Copy link

@pimenta pimenta commented Aug 28, 2013

I do not know if that is a bug.

I have updated and here goes the verbose output as required.

----- start
Ubuntu:~/Desktop$ [youtube] Setting language
[youtube] IrsKPKjGF_Y: Downloading video webpage
[youtube] IrsKPKjGF_Y: Downloading video info webpage
ERROR: unable to download video info webpage: HTTP Error 402: Payment Required; 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.

[1]+ Exit 1 youtube-dl -f 18 http://www.youtube.com/watch?v=IrsKPKjGF_Y

Ubuntu:/Desktop$ youtube-dl --verbose -f 18 http://www.youtube.com/watch?v=IrsKPKjGF_Y&
[1] 7401
Ubuntu:
/Desktop$ [debug] System config: []
[debug] User config: []
[debug] Command-line args: ['--verbose', '-f', '18', 'http://www.youtube.com/watch?v=IrsKPKjGF_Y']
[debug] youtube-dl version 2013.08.28
[debug] Python version 2.7.3 - Linux-3.2.0-52-generic-pae-i686-with-Ubuntu-12.04-precise
[debug] Proxy map: {}
[youtube] Setting language
[youtube] IrsKPKjGF_Y: Downloading video webpage
[youtube] IrsKPKjGF_Y: Downloading video info webpage
[youtube] Confirming age
ERROR: unable to download video info webpage: HTTP Error 402: Payment Required; 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.
File "/usr/local/bin/youtube-dl/youtube_dl/extractor/common.py", line 128, in _request_webpage
return compat_urllib_request.urlopen(url_or_request)
File "/usr/lib/python2.7/urllib2.py", line 126, in urlopen
return _opener.open(url, data, timeout)
File "/usr/lib/python2.7/urllib2.py", line 406, in open
response = meth(req, response)
File "/usr/lib/python2.7/urllib2.py", line 519, in http_response
'http', request, response, code, msg, hdrs)
File "/usr/lib/python2.7/urllib2.py", line 444, in error
return self._call_chain(_args)
File "/usr/lib/python2.7/urllib2.py", line 378, in _call_chain
result = func(_args)
File "/usr/lib/python2.7/urllib2.py", line 527, in http_error_default
raise HTTPError(req.get_full_url(), code, msg, hdrs, fp)

[1]+ Exit 1 youtube-dl --verbose -f 18 http://www.youtube.com/watch?v=IrsKPKjGF_Y
----- stop

@jaimeMF
Copy link
Collaborator

@jaimeMF jaimeMF commented Aug 28, 2013

Thanks for reporting, other users have already reported this problem : #1307, but I cannot reproduce the errors.

@jaimeMF jaimeMF closed this Aug 28, 2013
@pravsingh
Copy link

@pravsingh pravsingh commented Sep 8, 2013

is it because I exceeded the download limits?

I'm also getting the same error:

WARNING: unable to extract uploader nickname
vfndCiKYO40
ERROR: unable to download video info webpage: HTTP Error 402: Payment Required; please report this issue on https://yt-dl.org/bug .

============= verbose output =================

$youtube-dl --verbose -f 18 http://www.youtube.com/watch?v=vfndCiKYO40
[debug] System config: []
[debug] User config: []
[debug] Command-line args: ['--verbose', '-f', '18', 'http://www.youtube.com/watch?v=vfndCiKYO40']
[debug] youtube-dl version 2013.08.09
[debug] Python version 2.7.2 - Darwin-12.4.0-x86_64-i386-64bit
[debug] Proxy map: {}
[youtube] Setting language
[youtube] vfndCiKYO40: Downloading video webpage
[youtube] vfndCiKYO40: Downloading video info webpage
ERROR: unable to download video info webpage: HTTP Error 402: Payment Required; 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.
File "/usr/local/bin/youtube-dl/youtube_dl/extractor/common.py", line 121, in _request_webpage
return compat_urllib_request.urlopen(url_or_request)
File "/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/urllib2.py", line 126, in urlopen
return _opener.open(url, data, timeout)
File "/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/urllib2.py", line 400, in open
response = meth(req, response)
File "/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/urllib2.py", line 513, in http_response
'http', request, response, code, msg, hdrs)
File "/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/urllib2.py", line 438, in error
return self._call_chain(_args)
File "/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/urllib2.py", line 372, in _call_chain
result = func(_args)
File "/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/urllib2.py", line 521, in http_error_default
raise HTTPError(req.get_full_url(), code, msg, hdrs, fp)

@pravsingh
Copy link

@pravsingh pravsingh commented Sep 8, 2013

updated the tool but now getting different error for the same video:

$sudo youtube-dl --update
Password:
Updating to version 2013.09.07...
Updated youtube-dl. Restart youtube-dl to use the new version.

========== error =============

$youtube-dl --verbose -f 18 http://www.youtube.com/watch?v=vfndCiKYO40
[debug] System config: []
[debug] User config: []
[debug] Command-line args: ['--verbose', '-f', '18', 'http://www.youtube.com/watch?v=vfndCiKYO40']
[debug] youtube-dl version 2013.09.07
[debug] Python version 2.7.2 - Darwin-12.4.0-x86_64-i386-64bit
[debug] Proxy map: {}
[youtube] Setting language
[youtube] vfndCiKYO40: Downloading video webpage
[youtube] vfndCiKYO40: Downloading video info webpage
[youtube] vfndCiKYO40: Extracting video information
WARNING: unable to extract uploader nickname
WARNING: unable to extract html5 player; please report this issue on http://yt-dl.org/bug
[youtube] encrypted signature length 87 (42.44), itag 46, html5 player None
WARNING: unable to extract html5 player; please report this issue on http://yt-dl.org/bug
[youtube] encrypted signature length 87 (42.44), itag 37, html5 player None
WARNING: unable to extract html5 player; please report this issue on http://yt-dl.org/bug
[youtube] encrypted signature length 87 (42.44), itag 45, html5 player None
WARNING: unable to extract html5 player; please report this issue on http://yt-dl.org/bug
[youtube] encrypted signature length 87 (42.44), itag 102, html5 player None
WARNING: unable to extract html5 player; please report this issue on http://yt-dl.org/bug
[youtube] encrypted signature length 87 (42.44), itag 22, html5 player None
WARNING: unable to extract html5 player; please report this issue on http://yt-dl.org/bug
[youtube] encrypted signature length 87 (42.44), itag 84, html5 player None
WARNING: unable to extract html5 player; please report this issue on http://yt-dl.org/bug
[youtube] encrypted signature length 87 (42.44), itag 44, html5 player None
WARNING: unable to extract html5 player; please report this issue on http://yt-dl.org/bug
[youtube] encrypted signature length 87 (42.44), itag 35, html5 player None
WARNING: unable to extract html5 player; please report this issue on http://yt-dl.org/bug
[youtube] encrypted signature length 87 (42.44), itag 43, html5 player None
WARNING: unable to extract html5 player; please report this issue on http://yt-dl.org/bug
[youtube] encrypted signature length 87 (42.44), itag 100, html5 player None
WARNING: unable to extract html5 player; please report this issue on http://yt-dl.org/bug
[youtube] encrypted signature length 87 (42.44), itag 34, html5 player None
WARNING: unable to extract html5 player; please report this issue on http://yt-dl.org/bug
[youtube] encrypted signature length 87 (42.44), itag 18, html5 player None
WARNING: unable to extract html5 player; please report this issue on http://yt-dl.org/bug
[youtube] encrypted signature length 87 (42.44), itag 82, html5 player None
WARNING: unable to extract html5 player; please report this issue on http://yt-dl.org/bug
[youtube] encrypted signature length 87 (42.44), itag 5, html5 player None
WARNING: unable to extract html5 player; please report this issue on http://yt-dl.org/bug
[youtube] encrypted signature length 87 (42.44), itag 36, html5 player None
WARNING: unable to extract html5 player; please report this issue on http://yt-dl.org/bug
[youtube] encrypted signature length 87 (42.44), itag 17, html5 player None
ERROR: unable to download video
Traceback (most recent call last):
File "/usr/local/bin/youtube-dl/youtube_dl/YoutubeDL.py", line 573, in download
videos = self.extract_info(url)
File "/usr/local/bin/youtube-dl/youtube_dl/YoutubeDL.py", line 339, in extract_info
return self.process_ie_result(ie_result, download=download)
File "/usr/local/bin/youtube-dl/youtube_dl/YoutubeDL.py", line 422, in process_ie_result
for r in ie_result['entries']
File "/usr/local/bin/youtube-dl/youtube_dl/YoutubeDL.py", line 369, in process_ie_result
self.process_info(ie_result)
File "/usr/local/bin/youtube-dl/youtube_dl/YoutubeDL.py", line 550, in process_info
raise UnavailableVideoError(err)
UnavailableVideoError: HTTP Error 403: Forbidden

@bkvirendra
Copy link

@bkvirendra bkvirendra commented Sep 8, 2013

I m making use of Youtube-dl in my app: http://boxmydownloads.com/

It downloads your urls directly in your Dropbox (including videos from Youtube)

The link http://www.youtube.com/watch?v=vfndCiKYO40' works on Boxmydownloads, since its built on Youtube-dl, I m sure its not an issue with Youtube-dl.

It can be because the uploader has banned the video access from your Country.

@pravsingh
Copy link

@pravsingh pravsingh commented Sep 8, 2013

thanks! will try it out ur site.

I found out the reason. basically when this issue happens, I tried playing a video on youtube and I got below message:
"Sorry for the interruption. We have been receiving a large volume of requests from your network. To continue with your YouTube experience, please enter the verification code below."

once I verified by entering the captcha, it started working.

@pravsingh
Copy link

@pravsingh pravsingh commented Sep 8, 2013

hey Virendra,
do you support downloading whole playlist?

@pravsingh
Copy link

@pravsingh pravsingh commented Sep 8, 2013

try my repo, one of them is having that command.

@bkvirendra
Copy link

@bkvirendra bkvirendra commented Sep 8, 2013

not rightnow! We are using a very small portion of Youtube-dl.

But we are slowly adding more and more features to.

We'll keep you updated with it

@phihag
Copy link
Contributor

@phihag phihag commented Sep 8, 2013

@pravsingh As documented in our FAQ 402 errors are youtube's way of saying that you've downloaded too much. By the way, here are a few comments to your tools:

  • In ytlist, you don't need to invent an URL. Instead, passing the playlist ID directly to youtube-dl should work. I'm not sure what you want to do with the metadata only. Why don't you just call youtube-dl on the whole playlist in the first place?
  • In ytdownload: Why are you explicitly passing in -c? It is already the default (or more precisely, the default is letting youtube-dl do what is best in the situation).
  • In ytdownload: --max-quality --restrict-filenames is a bug, there's no such quality. Most likely, you wanted the highest available quality, and youtube-dl downloads that by default. It looks like you are on Linux; why do you want --restrict-filenames?
  • I'm not sure what the renaming business in yt2mp3 is about. Why do you do that?

I think you can just replace the whole ytlist / ytdownload with one evocation of

youtube-dl -i -o "%(title)s.%(ext)s" -k -x --audio-format mp3 PL18969FDC598E971F
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
5 participants
You can’t perform that action at this time.