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

SoundCloud download failure: HTTP 501 #22278

Closed
tripulse opened this issue Aug 31, 2019 · 5 comments
Closed

SoundCloud download failure: HTTP 501 #22278

tripulse opened this issue Aug 31, 2019 · 5 comments

Comments

@tripulse
Copy link

@tripulse tripulse commented Aug 31, 2019

Checklist

  • I'm reporting a broken site support issue
  • I've verified that I'm running youtube-dl version 2019.08.13
  • I've checked that all provided URLs are alive and playable in a browser
  • I've checked that all URLs and arguments with special characters are properly quoted or escaped
  • I've searched the bugtracker for similar bug reports including closed ones
  • I've read bugs section in FAQ

Verbose log

[debug] System config: []
[debug] User config: []
[debug] Custom config: []
[debug] Command-line args: ['-f', 'best', '-o', '%YTD_FS%', 'soundcloud.com/nocopyrightsounds/tracks', '--verbose']
[debug] Encodings: locale cp1252, fs utf-8, out utf-8, pref cp1252
[debug] youtube-dl version 2019.08.13
[debug] Python version 3.7.4 (CPython) - Windows-8.1-6.3.9600-SP0
[debug] exe versions: ffmpeg N-94303-g39db2af0c2-gaf5f770113, ffprobe N-94303-g39db2af0c2-gaf5f770113, rtmpdump 2.4-20190330-gc5f04a5-GnuTLS_3.6.8-x86_64-static
[debug] Proxy map: {}
WARNING: The url doesn't specify the protocol, trying with http
[soundcloud:user] nocopyrightsounds: Downloading user info
[soundcloud:user] 16069159: Downloading track page 1
[soundcloud:user] 16069159: Downloading track page 2
[soundcloud:user] 16069159: Downloading track page 3
[soundcloud:user] 16069159: Downloading track page 4
[soundcloud:user] 16069159: Downloading track page 5
[soundcloud:user] 16069159: Downloading track page 6
[soundcloud:user] 16069159: Downloading track page 7
[soundcloud:user] 16069159: Downloading track page 8
[soundcloud:user] 16069159: Downloading track page 9
[soundcloud:user] 16069159: Downloading track page 10
[soundcloud:user] 16069159: Downloading track page 11
[soundcloud:user] 16069159: Downloading track page 12
[soundcloud:user] 16069159: Downloading track page 13
[soundcloud:user] 16069159: Downloading track page 14
[soundcloud:user] 16069159: Downloading track page 15
[soundcloud:user] 16069159: Downloading track page 16
[soundcloud:user] 16069159: Downloading track page 17
[soundcloud:user] 16069159: Downloading track page 18
[soundcloud:user] 16069159: Downloading track page 19
[soundcloud:user] 16069159: Downloading track page 20
[download] Downloading playlist: NCS (Tracks)
[soundcloud:user] playlist NCS (Tracks): Collected 609 video ids (downloading 609 of them)
[download] Downloading video 1 of 609
[soundcloud] nocopyrightsounds/max-brhon-cyberpunk-ncs-release: Downloading webpage
[soundcloud] nocopyrightsounds/max-brhon-cyberpunk-ncs-release: Downloading info JSON
[soundcloud] 673226525: Downloading track url
[soundcloud] 673226525: Downloading m3u8 information
[soundcloud] 673226525: Downloading m3u8 information
[debug] Invoking downloader on 'https://cf-media.sndcdn.com/X3A97BKjYsP9.128.mp3?Policy=eyJTdGF0ZW1lbnQiOlt7IlJlc291cmNlIjoiKjovL2NmLW1lZGlhLnNuZGNkbi5jb20vWDNBOTdCS2pZc1A5LjEyOC5tcDMiLCJDb25kaXRpb24iOnsiRGF0ZUxlc3NUaGFuIjp7IkFXUzpFcG9jaFRpbWUiOjE1NjcyNjY0Nzl9fX1dfQ__&Signature=E9634fM23eHKYu569lnruWeL-2vBQcNvtnFGOQGhcuZHr412XaLAkbz2KMnVhp1jIGmIt5z1~kmUPwVMa3NGlra7ySAmnlKxyfhP~iZ5Tr867ku6VakQYeCU2Nfi2KARB4K0kRq3~LlIzVMbxZT5R2pSF0DEjUm8krG-KAYzgyh~e8XzQr4edwoJDymSgobv2ta9h4957Oi1yWV~MncVNsQZjL5jzU~L1yzcvGRTPjvFLMW2fp-SdrHxzjQGUkhZcKNzsi5lH5zhXhlaVa3JB1Z0EPAW0DJGeyepxu1cFuCfAkzMGD7eqmMK1SZfCvRLMDqQ6mHPkCRUoc~6sfa-Ww__&Key-Pair-Id=APKAI6TU7MMXM5DG6EPQ'
[download] Destination: Max Brhon - Cyberpunk [NCS Release].mp3
[download] 100% of 3.28MiB in 00:04
...
[download] Downloading video 48 of 609
[soundcloud] nocopyrightsounds/whales-ggnoaa-paranoia-ncs-release: Downloading webpage
WARNING: Unable to download webpage: HTTP Error 503: Service Unavailable
Traceback (most recent call last):
  File "c:\users\nullptr\appdata\local\programs\python\python37\lib\runpy.py", line 193, in _run_module_as_main
    "__main__", mod_spec)
  File "c:\users\nullptr\appdata\local\programs\python\python37\lib\runpy.py", line 85, in _run_code
    exec(code, run_globals)
  File "C:\Users\nullptr\AppData\Local\Programs\Python\Python37\Scripts\youtube-dl.exe\__main__.py", line 9, in <module>
  File "c:\users\nullptr\appdata\local\programs\python\python37\lib\site-packages\youtube_dl\__init__.py", line 474, in main
    _real_main(argv)
  File "c:\users\nullptr\appdata\local\programs\python\python37\lib\site-packages\youtube_dl\__init__.py", line 464, in _real_main
    retcode = ydl.download(all_urls)
  File "c:\users\nullptr\appdata\local\programs\python\python37\lib\site-packages\youtube_dl\YoutubeDL.py", line 2010, in download
    url, force_generic_extractor=self.params.get('force_generic_extractor', False))
  File "c:\users\nullptr\appdata\local\programs\python\python37\lib\site-packages\youtube_dl\YoutubeDL.py", line 807, in extract_info
    return self.process_ie_result(ie_result, download, extra_info)
  File "c:\users\nullptr\appdata\local\programs\python\python37\lib\site-packages\youtube_dl\YoutubeDL.py", line 868, in process_ie_result
    extra_info=extra_info)
  File "c:\users\nullptr\appdata\local\programs\python\python37\lib\site-packages\youtube_dl\YoutubeDL.py", line 807, in extract_info
    return self.process_ie_result(ie_result, download, extra_info)
  File "c:\users\nullptr\appdata\local\programs\python\python37\lib\site-packages\youtube_dl\YoutubeDL.py", line 1006, in process_ie_result
    extra_info=extra)
  File "c:\users\nullptr\appdata\local\programs\python\python37\lib\site-packages\youtube_dl\YoutubeDL.py", line 868, in process_ie_result
    extra_info=extra_info)
  File "c:\users\nullptr\appdata\local\programs\python\python37\lib\site-packages\youtube_dl\YoutubeDL.py", line 796, in extract_info
    ie_result = ie.extract(url)
  File "c:\users\nullptr\appdata\local\programs\python\python37\lib\site-packages\youtube_dl\extractor\common.py", line 530, in extract
    ie_result = self._real_extract(url)
  File "c:\users\nullptr\appdata\local\programs\python\python37\lib\site-packages\youtube_dl\extractor\soundcloud.py", line 446, in _real_extract
    info_json_url, full_title, 'Downloading info JSON')
UnboundLocalError: local variable 'info_json_url' referenced before assignment

Description

I was trying to download all the tracks of a user from SoundCloud. I went doing some other work and left it running in background. When I came back and inspected the console and noticed the operation was interrupted. I retried but alas, it didn't work.

Each time I download the tracks an issue pops up. Such as — 401: Unauthorized, 503: Service Unavialable. It never occurred with any other link (aleast what I remember).

I have two suspects. Either SoundCloud is working improperly or the Extractor code for SoundCloud is malfunctioning. Hope, the information gave might solve the issue.

@megascrapper
Copy link

@megascrapper megascrapper commented Sep 1, 2019

I wasn't able to reproduce the issue. Everything downloads perfectly for me.
Maybe because I'm on a Mac (don't have access to Windows machines atm)

[debug] System config: []
[debug] User config: []
[debug] Custom config: []
[debug] Command-line args: [u'--ignore-config', u'-v', u'https://soundcloud.com/nocopyrightsounds/tracks']
[debug] Encodings: locale UTF-8, fs utf-8, out UTF-8, pref UTF-8
[debug] youtube-dl version 2019.08.13
[debug] Python version 2.7.16 (CPython) - Darwin-18.7.0-x86_64-i386-64bit
[debug] exe versions: ffmpeg 4.1.4, ffprobe 4.1.4, rtmpdump 2.4
[debug] Proxy map: {}
[soundcloud:user] nocopyrightsounds: Downloading user info
[soundcloud:user] 16069159: Downloading track page 1
[soundcloud:user] 16069159: Downloading track page 2
[soundcloud:user] 16069159: Downloading track page 3
[soundcloud:user] 16069159: Downloading track page 4
[soundcloud:user] 16069159: Downloading track page 5
[soundcloud:user] 16069159: Downloading track page 6
[soundcloud:user] 16069159: Downloading track page 7
[soundcloud:user] 16069159: Downloading track page 8
[soundcloud:user] 16069159: Downloading track page 9
[soundcloud:user] 16069159: Downloading track page 10
[soundcloud:user] 16069159: Downloading track page 11
[soundcloud:user] 16069159: Downloading track page 12
[soundcloud:user] 16069159: Downloading track page 13
[soundcloud:user] 16069159: Downloading track page 14
[soundcloud:user] 16069159: Downloading track page 15
[soundcloud:user] 16069159: Downloading track page 16
[soundcloud:user] 16069159: Downloading track page 17
[soundcloud:user] 16069159: Downloading track page 18
[soundcloud:user] 16069159: Downloading track page 19
[soundcloud:user] 16069159: Downloading track page 20
[download] Downloading playlist: NCS (Tracks)
[soundcloud:user] playlist NCS (Tracks): Collected 609 video ids (downloading 609 of them)
[download] Downloading video 1 of 609
[soundcloud] nocopyrightsounds/max-brhon-cyberpunk-ncs-release: Downloading webpage
[soundcloud] nocopyrightsounds/max-brhon-cyberpunk-ncs-release: Downloading info JSON
[soundcloud] 673226525: Downloading track url
[soundcloud] 673226525: Downloading m3u8 information
[soundcloud] 673226525: Downloading m3u8 information
[debug] Default format spec: bestvideo+bestaudio/best
[debug] Invoking downloader on u'https://cf-media.sndcdn.com/X3A97BKjYsP9.128.mp3?Policy=eyJTdGF0ZW1lbnQiOlt7IlJlc291cmNlIjoiKjovL2NmLW1lZGlhLnNuZGNkbi5jb20vWDNBOTdCS2pZc1A5LjEyOC5tcDMiLCJDb25kaXRpb24iOnsiRGF0ZUxlc3NUaGFuIjp7IkFXUzpFcG9jaFRpbWUiOjE1NjczNDM3Nzl9fX1dfQ__&Signature=TEjgyuThSO2hh~pX8PvadbzYqAuRfDrNUTrp8QawtvBf~DHRGH26W7fAubBumq88JT9I~xcSdwSzu7Nkgj2e-K3PHjZ4BDcA5Sx9zPZwvQjXSvJbni1eFPJZDwqU7pbztXHOyTfQUNqstdfOpC478XtskWgRdRg0a-3Up7s-sRGrvzcX0iNRLI72gEMCtA9bPAOqXLTXv0qxMtDP~XU18yjwuIEhVhelOjX83iahd3TmHKk320rfMNr4WHAlcK9apT4HkB1zvl8f6KzHnbfNnoEuQJqxV5mbF9c73CLZI87k33eQP2xTX-w9LBw09bnzTVGwsIu71ilBT~vgbHS6RQ__&Key-Pair-Id=APKAI6TU7MMXM5DG6EPQ'
[download] Destination: Max Brhon - Cyberpunk [NCS Release]-673226525.mp3
[download] 100% of 3.28MiB in 00:14
[download] Downloading video 2 of 609
[soundcloud] nocopyrightsounds/ascence-about-youmaster-wav: Downloading webpage
[soundcloud] nocopyrightsounds/ascence-about-youmaster-wav: Downloading info JSON
[soundcloud] 655303598: Downloading track url
[soundcloud] 655303598: Downloading m3u8 information
[soundcloud] 655303598: Downloading m3u8 information
[debug] Default format spec: bestvideo+bestaudio/best
[debug] Invoking downloader on u'https://cf-media.sndcdn.com/izpYDvD8OAbr.128.mp3?Policy=eyJTdGF0ZW1lbnQiOlt7IlJlc291cmNlIjoiKjovL2NmLW1lZGlhLnNuZGNkbi5jb20vaXpwWUR2RDhPQWJyLjEyOC5tcDMiLCJDb25kaXRpb24iOnsiRGF0ZUxlc3NUaGFuIjp7IkFXUzpFcG9jaFRpbWUiOjE1NjczNDM3ODh9fX1dfQ__&Signature=SbjyYLT0D7r8MEWdKzn3CV1A-s4O2RZ24jr8BvEfP3FXVOF7stpLG3z2Mc6bShS~UPV59W2cwhH3s097Y-HEt5MAv5IpBDjiqXsV2VoMNQo4BDePfRwieLhS8yRGW3B7mlTWxDVOjsGqUlZn2EU3Ou~9GmBI0yoo9W1pOy46~BSPJcuxC8r4Y2xg4uIfbOXYYqqwiI0TS7II38F8CoH2dRkmHXYYWKS8r-iYM49IXINUXCv7eUJ0OGIeHZ2fCihXs4vzNwJJAQZaOQpv5ml-1sL2-qW4mYUycyrl~GFbTVal55DhOSsKQwY0~S4gc89vrE0Gkx1wDY~pqu8XY3ws9g__&Key-Pair-Id=APKAI6TU7MMXM5DG6EPQ'
[download] Destination: Ascence - About You [NCS Release]-655303598.mp3
[download] 100% of 2.81MiB in 01:45
[download] Downloading video 3 of 609
[soundcloud] nocopyrightsounds/roy-levy-roy-breathe-me-in-ncs-release: Downloading webpage
[soundcloud] nocopyrightsounds/roy-levy-roy-breathe-me-in-ncs-release: Downloading info JSON
[soundcloud] 655302629: Downloading track url
[soundcloud] 655302629: Downloading m3u8 information
[soundcloud] 655302629: Downloading m3u8 information
[debug] Default format spec: bestvideo+bestaudio/best
[debug] Invoking downloader on u'https://cf-media.sndcdn.com/LtrF7hQumb5q.128.mp3?Policy=eyJTdGF0ZW1lbnQiOlt7IlJlc291cmNlIjoiKjovL2NmLW1lZGlhLnNuZGNkbi5jb20vTHRyRjdoUXVtYjVxLjEyOC5tcDMiLCJDb25kaXRpb24iOnsiRGF0ZUxlc3NUaGFuIjp7IkFXUzpFcG9jaFRpbWUiOjE1NjczNDM5NDF9fX1dfQ__&Signature=DNCNW84KU6Oe0fEaaP3cje5rO~8UXCVAWLxAtp3e1fVcZ8p2XLjAFKTMFcA5E4F2IU7Vzxe89ToDqmGaUYvRKpPUSdZMT9JScz2urJ0FhglPxEu8aM6ETHKfXMZIr19dc4YIMtp2mWgt7HfKHuYrncahDCA93xgOw4FAki0UkhE~qkXY8lJoC5F14w7ci-8PG~dEz~qkkCy4To6Q2lh~F3-dyE4wU5SmqnX5xS2FgCzx9WJnEpl0SEeFJa6VazBYA77kE~Mp5NtGDHCeioRmg2kpjtZlBEc80e0BKpPPm87HnGigvHoZTLz7ZXzdOPHnqsZHSGMLKqLvWMd75Ur73A__&Key-Pair-Id=APKAI6TU7MMXM5DG6EPQ'
[download] Destination: ROY - Breathe Me In [NCS Release]-655302629.mp3
[download] 100% of 3.02MiB in 00:05
...

You can try the following:

  • Update to the latest version of youtube-dl (2019.09.01 is released just a few hours ago)
  • Run with no command arguments
  • Try opening the page on the browser on multiple devices. If it throws an error, loads very slow or doesn't load at all (even with good internet) then maybe SoundCloud blocks your IP address (not sure about this one, I had a similar issue a while back after downloading too many tracks)
@tripulse
Copy link
Author

@tripulse tripulse commented Sep 5, 2019

I'd try the newest version. And, I will report if any error occurs.

@tripulse
Copy link
Author

@tripulse tripulse commented Sep 6, 2019

Oh crap, it happend again. This error is haunting me like a ghost.

[download] Downloading video 1 of 593
[soundcloud] nocopyrightsounds/marin-hoxha-endless-ncs-release: Downloading webpage
[soundcloud] nocopyrightsounds/marin-hoxha-endless-ncs-release: Downloading info JSON
[soundcloud] 582849012: Downloading track url
WARNING: Unable to download JSON metadata: HTTP Error 401: Unauthorized
[soundcloud] 582849012: Checking fallback video format URL
[soundcloud] 582849012: fallback video format URL is invalid, skipping
ERROR: No video formats found; 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.

For my job I'm using (2019.09.01) version. Still, errors are being occurred!

@megascrapper
Copy link

@megascrapper megascrapper commented Sep 8, 2019

Does the page loads fine in your browser?

@tripulse
Copy link
Author

@tripulse tripulse commented Sep 8, 2019

It loads, perfectly fine in my browser. No issues!


Some information about my System. I hope it would help the developers debug.

Browser: Google Chrome
Version: 76.0
Host OS: Windows 8.1
Shell: bash

I'm planning to retry the process by changing the User-Agent. I'd let you know results.

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
3 participants
You can’t perform that action at this time.