[Soundcloud] HTTP 401 Error #9270

Closed
opened 2026-02-21 05:00:52 -05:00 by deekerman · 7 comments
Owner

Originally created by @chriscz on GitHub (Nov 30, 2016).

  • I've verified and I assure that I'm running youtube-dl 2016.11.27

Before submitting an issue make sure you have:

  • At least skimmed through README and most notably FAQ and BUGS sections
  • Searched the bugtracker for similar issues including closed ones

What is the purpose of your issue?

  • Bug report (encountered problems with youtube-dl)
  • Site support request (request for adding support for a new site)
  • Feature request (request for a new functionality)
  • Question
  • Other

If the purpose of this issue is a bug report, site support request or you are not completely sure provide the full verbose output.

$ youtube-dl "https://soundcloud.com/besvendsen/be-svendsen-live-icarus-burning-man-2016" --verbose
[debug] System config: []
[debug] User config: []
[debug] Command-line args: [u'https://soundcloud.com/besvendsen/be-svendsen-live-icarus-burning-man-2016', u'--verbose']
[debug] Encodings: locale UTF-8, fs UTF-8, out UTF-8, pref UTF-8
[debug] youtube-dl version 2016.11.27
[debug] Python version 2.7.6 - Linux-3.13.0-97-generic-x86_64-with-Ubuntu-14.04-trusty
[debug] exe versions: ffmpeg N-76045-g97be5d4, ffprobe N-76045-g97be5d4
[debug] Proxy map: {}
[soundcloud] besvendsen/be-svendsen-live-icarus-burning-man-2016: Resolving id
[soundcloud] besvendsen/be-svendsen-live-icarus-burning-man-2016: Downloading info JSON
ERROR: Unable to download JSON metadata: HTTP Error 401: Unauthorized (caused by HTTPError()); 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.
  File "/usr/local/lib/python2.7/dist-packages/youtube_dl/extractor/common.py", line 404, in _request_webpage
    return self._downloader.urlopen(url_or_request)
  File "/usr/local/lib/python2.7/dist-packages/youtube_dl/YoutubeDL.py", line 2001, in urlopen
    return self._opener.open(req, timeout=self._socket_timeout)
  File "/usr/lib/python2.7/urllib2.py", line 410, in open
    response = meth(req, response)
  File "/usr/lib/python2.7/urllib2.py", line 523, in http_response
    'http', request, response, code, msg, hdrs)
  File "/usr/lib/python2.7/urllib2.py", line 448, in error
    return self._call_chain(*args)
  File "/usr/lib/python2.7/urllib2.py", line 382, in _call_chain
    result = func(*args)
  File "/usr/lib/python2.7/urllib2.py", line 531, in http_error_default
    raise HTTPError(req.get_full_url(), code, msg, hdrs, fp)

Description

  • I have tried logging in / providing credentials on the commandline to no effect

Confirmed Fix

  • Update the _CLIENT_ID in soundcloud.py
Originally created by @chriscz on GitHub (Nov 30, 2016). - [x] I've **verified** and **I assure** that I'm running youtube-dl **2016.11.27** ### Before submitting an *issue* make sure you have: - [x] At least skimmed through [README](https://github.com/rg3/youtube-dl/blob/master/README.md) and **most notably** [FAQ](https://github.com/rg3/youtube-dl#faq) and [BUGS](https://github.com/rg3/youtube-dl#bugs) sections - [x] [Searched](https://github.com/rg3/youtube-dl/search?type=Issues) the bugtracker for similar issues including closed ones ### What is the purpose of your *issue*? - [x] Bug report (encountered problems with youtube-dl) - [ ] Site support request (request for adding support for a new site) - [ ] Feature request (request for a new functionality) - [ ] Question - [ ] Other ### If the purpose of this *issue* is a *bug report*, *site support request* or you are not completely sure provide the full verbose output. ``` $ youtube-dl "https://soundcloud.com/besvendsen/be-svendsen-live-icarus-burning-man-2016" --verbose [debug] System config: [] [debug] User config: [] [debug] Command-line args: [u'https://soundcloud.com/besvendsen/be-svendsen-live-icarus-burning-man-2016', u'--verbose'] [debug] Encodings: locale UTF-8, fs UTF-8, out UTF-8, pref UTF-8 [debug] youtube-dl version 2016.11.27 [debug] Python version 2.7.6 - Linux-3.13.0-97-generic-x86_64-with-Ubuntu-14.04-trusty [debug] exe versions: ffmpeg N-76045-g97be5d4, ffprobe N-76045-g97be5d4 [debug] Proxy map: {} [soundcloud] besvendsen/be-svendsen-live-icarus-burning-man-2016: Resolving id [soundcloud] besvendsen/be-svendsen-live-icarus-burning-man-2016: Downloading info JSON ERROR: Unable to download JSON metadata: HTTP Error 401: Unauthorized (caused by HTTPError()); 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. File "/usr/local/lib/python2.7/dist-packages/youtube_dl/extractor/common.py", line 404, in _request_webpage return self._downloader.urlopen(url_or_request) File "/usr/local/lib/python2.7/dist-packages/youtube_dl/YoutubeDL.py", line 2001, in urlopen return self._opener.open(req, timeout=self._socket_timeout) File "/usr/lib/python2.7/urllib2.py", line 410, in open response = meth(req, response) File "/usr/lib/python2.7/urllib2.py", line 523, in http_response 'http', request, response, code, msg, hdrs) File "/usr/lib/python2.7/urllib2.py", line 448, in error return self._call_chain(*args) File "/usr/lib/python2.7/urllib2.py", line 382, in _call_chain result = func(*args) File "/usr/lib/python2.7/urllib2.py", line 531, in http_error_default raise HTTPError(req.get_full_url(), code, msg, hdrs, fp) ``` ### Description - I have tried logging in / providing credentials on the commandline to no effect ### Confirmed Fix - Update the _CLIENT_ID in soundcloud.py
Author
Owner

@vaibhav1312 commented on GitHub (Nov 30, 2016):

Last time when this error occurred, they changed the 'client id' here is the link to similar previous bug https://github.com/rg3/youtube-dl/issues/6930

@vaibhav1312 commented on GitHub (Nov 30, 2016): Last time when this error occurred, they changed the 'client id' here is the link to similar previous bug https://github.com/rg3/youtube-dl/issues/6930
Author
Owner

@chriscz commented on GitHub (Nov 30, 2016):

You are correct. I just changed the client ID and it seems to work fine now.

@chriscz commented on GitHub (Nov 30, 2016): You are correct. I just changed the client ID and it seems to work fine now.
Author
Owner

@0rvar commented on GitHub (Nov 30, 2016):

@chriscz How did you change the client ID, and to what? Is this something that can be done in config, or do you need to rebuild youtube-dl from source?

@0rvar commented on GitHub (Nov 30, 2016): @chriscz How did you change the client ID, and to what? Is this something that can be done in config, or do you need to rebuild youtube-dl from source?
Author
Owner

@chriscz commented on GitHub (Nov 30, 2016):

I just updated it in source. I assume you would have to register for a client ID for a legitimate one. It would be best to wait for the developers to generate a new one.

A temporary fix would be updating github.com/dabiboo/youtube-dl@6c7975d3ad as shown in issue #6930

@chriscz commented on GitHub (Nov 30, 2016): I just updated it in source. I assume you would have to register for a client ID for a legitimate one. It would be best to wait for the developers to generate a new one. A temporary fix would be updating https://github.com/dabiboo/youtube-dl/commit/6c7975d3ade536b2cccebadec3ab7f4cd9510700 as shown in issue #6930
Author
Owner

@vaibhav1312 commented on GitHub (Nov 30, 2016):

@chriscz Can you please tell me the client id that you changed. And, what exactly did you change client_id or iphone_client_id

@vaibhav1312 commented on GitHub (Nov 30, 2016): @chriscz Can you please tell me the client id that you changed. And, what exactly did you change client_id or iphone_client_id
Author
Owner

@chriscz commented on GitHub (Nov 30, 2016):

@vaibhav1312 Exactly the one changed in the commit I mention above (extractors/soundcloud.py:124) . I just searched the internet for an alternative one. It's not worth submitting a pull-request, because the core developers probably want to create a client identifier they have control over.

@chriscz commented on GitHub (Nov 30, 2016): @vaibhav1312 Exactly the one changed in the commit I mention above (`extractors/soundcloud.py:124`) . I just searched the internet for an alternative one. It's not worth submitting a pull-request, because the core developers probably want to create a client identifier they have control over.
Author
Owner

@tomtastic commented on GitHub (Dec 28, 2016):

Thanks calbrecht!

@tomtastic commented on GitHub (Dec 28, 2016): Thanks calbrecht!
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
starred/youtube-dl-ytdl-org#9270
No description provided.