spotDL / spotify-downloader

Download your Spotify playlists and songs along with album art and metadata (from YouTube if a match is found).
https://spotdl.readthedocs.io/en/latest/
MIT License
17.49k stars 1.61k forks source link

Spotdl Crashes after processing querries #1878

Closed enzomtpYT closed 1 year ago

enzomtpYT commented 1 year ago

System OS

Windows

Python Version

3.10 (CPython)

Install Source

pip / PyPi

Install version / commit hash

v4.2.0

Expected Behavior vs Actual Behavior

Excpected behavior : The querries sould be ending and then search for the musics in playlists and finally download all the musics.

Actual Behavior : The querries process always fine, randomly (sometimes it works and sometimes it doesn't) does the search for the musics in playlists and never downloads the actual musics

Steps to reproduce - Ensure to include actual links!

  1. Download SpotDL V4.2.0
  2. Create a musics.sync.spotdl with lots of music to download
  3. Use the previous file with sync function
  4. Wait for the querries to process
  5. Bug hapening

Traceback

:\Partages\Assets>spotdl sync musics.sync.spotdl --format mp3 --output "Musics/{artist}/{title}.{output-ext}" --overwrite skip --bitrate 320k --threads 16 --config --m3u playlist.m3u --max-retries 5000 --use-cache
Processing query: https://open.spotify.com/artist/53XhwfbYqKCa1cC15pYq2q
Processing query: https://open.spotify.com/playlist/4br15pxVuXjr4qU0KBfWMY
Processing query: https://open.spotify.com/playlist/37i9dQZF1DXblmY5UIU3v3
Processing query: https://open.spotify.com/playlist/2INV6A28riGzcxVbaGdFEj
Processing query: https://open.spotify.com/playlist/37i9dQZF1E4nPxD8D3A5X8
Processing query: https://open.spotify.com/artist/36JJbH66Q0tZbKcnjvliDT
Processing query: https://open.spotify.com/artist/3zYU33YUxJPzsPrYmpMMiu
Processing query: https://open.spotify.com/artist/3YJDqtTSjydvUpTvU1fJ6O
Processing query: https://open.spotify.com/playlist/49BVzg9khU4gahhXbyKQZM
Processing query: https://open.spotify.com/playlist/5f6QseEksL1FNFVzQcgJgC
Processing query: https://open.spotify.com/artist/6BxtVo9reMQ2vff0l8HMGY
Processing query: https://open.spotify.com/artist/1gmwm51vXSRWAt3J8bBdO3
Processing query: https://open.spotify.com/artist/5eYIGMKb2BdsIXbScrOPK2
Processing query: https://open.spotify.com/artist/2M1EOE4J6tnaLCfMhE3eFq
Processing query: https://open.spotify.com/playlist/1LdkJOaBVrlyf5F3oijXbF
Processing query: https://open.spotify.com/artist/5AqhBC5pt6b0WVpUAII1Ro
Processing query: https://open.spotify.com/playlist/2x5ST1hmLc8TjA1Ybp5Hh7
Processing query: https://open.spotify.com/playlist/09rQgqnmP26wLv7EK4GCwr
Processing query: https://open.spotify.com/playlist/4M5EDY72Y2RmljqZwrJVvE
Processing query: https://open.spotify.com/playlist/4kR9oczE6zpsg3OGeftphB
Processing query: https://open.spotify.com/playlist/0pwcV257JtjlsPZfccinrb
Processing query: https://open.spotify.com/playlist/12De0szTOpqk7brqebkjtl
Processing query: https://open.spotify.com/playlist/10qkoUHZdgMIkeWjjRLGrO
Processing query: https://open.spotify.com/playlist/4M2EwzhQSyLeWIWrXGuRjs
Processing query: https://open.spotify.com/playlist/6kFJZeMre5N7apwNAUjRiC
Processing query: https://open.spotify.com/playlist/2qKw3MEA349w9xrYOrzJQp
Processing query: https://open.spotify.com/artist/1T7zBkQCOCacKjbnmFX7cp
Processing query: https://open.spotify.com/playlist/3q4ZG9lbbTsMvPh8anJToT
Processing query: https://open.spotify.com/playlist/10sRxEG1izknAtP68LXaVu
Processing query: https://open.spotify.com/playlist/170lnBbynpWQkjqWi8DEBb
Processing query: https://open.spotify.com/artist/41rVuRHYAiH7ltBTHVR9We
Processing query: https://open.spotify.com/playlist/74hXAfZO0C1n15qiIxDPQq
Processing query: https://open.spotify.com/playlist/1tit90E95fHdTpVhgTCp0b
Processing query: https://open.spotify.com/playlist/5uuhBqQ6JNbhzk2Cx5hwzc
Processing query: https://open.spotify.com/artist/1gZm7WtVj8XuaRWeN0Ft6s
Processing query: https://open.spotify.com/playlist/5Zw3I10nXlY2bDKXED4o1z
Processing query: https://open.spotify.com/playlist/6x4Maul383TzxHxIeiEHt9
Processing query: https://open.spotify.com/playlist/4KlQNKIQAYFCpXiDj8vULT
Processing query: https://open.spotify.com/playlist/1NLcaJypLvcppBbwYMts7u
Processing query: https://open.spotify.com/artist/5FRbx6DhrJm4IXMN72bVVN
Processing query: https://open.spotify.com/artist/71LY5vz7tLIHyUvmqQm52e
Processing query: https://open.spotify.com/playlist/37i9dQZF1E8NDeQbHqpmxD
Processing query: https://open.spotify.com/playlist/3jlRj9KxNEiNRABzwz24Xk
Processing query: https://open.spotify.com/playlist/5xMHmDKcFfkLK5Cf5FufSG
Processing query: https://open.spotify.com/playlist/37i9dQZF1EIUC9rFQMfclz
Processing query: https://open.spotify.com/playlist/37i9dQZF1EIVbhHYLUiCSU
Processing query: https://open.spotify.com/playlist/37i9dQZF1EpCuaqgASnQbJ
Processing query: https://open.spotify.com/playlist/37i9dQZF1EuyYzHZwQ73e2
Processing query: https://open.spotify.com/playlist/37i9dQZF1EpjTlrfjv7d4F
Processing query: https://open.spotify.com/playlist/37i9dQZF1DX4eRPd9frC1m
Processing query: https://open.spotify.com/playlist/37i9dQZF1DWWpHR8v2FGW4
Processing query: https://open.spotify.com/playlist/4bqjKaiplYLlIj1jBAcrpg
Processing query: https://open.spotify.com/playlist/1CYDGsx7W8Ju3AEBFtdQ1q
Processing query: https://open.spotify.com/playlist/1le3H0ACKc5EezfcWQeJ6T
Processing query: https://open.spotify.com/playlist/658fQIGrorpdjSEmSrPG6Q
Processing query: https://open.spotify.com/playlist/37i9dQZF1DWWY64wDtewQt
Processing query: https://open.spotify.com/playlist/5ggSrfgLiMRLQC43mPnpau
Processing query: https://open.spotify.com/playlist/0Wl05KLOCgwUBQJKNGKTdl
Processing query: https://open.spotify.com/playlist/10eqaihd0jcOPf6Xuf33fO
Processing query: https://open.spotify.com/playlist/70RU8iaRuuPlNBq7cibSdn
Processing query: https://open.spotify.com/artist/62kkHDcyLqIaSSLni1TCAp
Processing query: https://open.spotify.com/artist/5he5w2lnU9x7JFhnwcekXX
Processing query: https://open.spotify.com/playlist/6vhHYHQq4T3nLhXdpmZpZ5
Processing query: https://open.spotify.com/artist/20UYCAvAHJ1WqrCElptD7O
Processing query: https://open.spotify.com/artist/5EEuae5uigQnwgYCl0s8EF
Processing query: https://open.spotify.com/artist/4bwIf0yXJf0F9AmOl2J78M
Processing query: https://open.spotify.com/artist/0ycHhPwPvoaO4VGzmMnXGq
Processing query: https://open.spotify.com/artist/5D3fvICIoElbyhNqbClhPT
Processing query: https://open.spotify.com/artist/3K0GDmmiRwn1Zc7RZzTeAz
Processing query: https://open.spotify.com/artist/3bwENxqj9nhaAI3fsAwmv9
Processing query: https://open.spotify.com/artist/7dGJo4pcD2V6oG8kP0tJRR
Processing query: https://open.spotify.com/artist/3z97WMRi731dCvKklIf2X6
Processing query: https://open.spotify.com/artist/7y2jKZBgvt5YV9jpKQUN5a
Processing query: https://open.spotify.com/artist/3R4VCoPt7V1poOWpdU43X8
Processing query: https://open.spotify.com/artist/0I6yADrmeyvw66g7yjkqIF
Max Retries reached

An error occurred
ResponseError: too many 429 error responses

The above exception was the direct cause of the following exception:

╭───────────────────────────────────────── Traceback (most recent call last) ──────────────────────────────────────────╮
│ C:\Users\enzoj\AppData\Local\Programs\Python\Python310\lib\site-packages\requests\adapters.py:486 in send            │
│                                                                                                                      │
│   483 │   │   │   timeout = TimeoutSauce(connect=timeout, read=timeout)                                              │
│   484 │   │                                                                                                          │
│   485 │   │   try:                                                                                                   │
│ ❱ 486 │   │   │   resp = conn.urlopen(                                                                               │
│   487 │   │   │   │   method=request.method,                                                                         │
│   488 │   │   │   │   url=url,                                                                                       │
│   489 │   │   │   │   body=request.body,                                                                             │
│                                                                                                                      │
│ C:\Users\enzoj\AppData\Local\Programs\Python\Python310\lib\site-packages\urllib3\connectionpool.py:941 in urlopen    │
│                                                                                                                      │
│    938 │   │   │   response.drain_conn()                                                                             │
│    939 │   │   │   retries.sleep(response)                                                                           │
│    940 │   │   │   log.debug("Retry: %s", url)                                                                       │
│ ❱  941 │   │   │   return self.urlopen(                                                                              │
│    942 │   │   │   │   method,                                                                                       │
│    943 │   │   │   │   url,                                                                                          │
│    944 │   │   │   │   body,                                                                                         │
│                                                                                                                      │
│ C:\Users\enzoj\AppData\Local\Programs\Python\Python310\lib\site-packages\urllib3\connectionpool.py:941 in urlopen    │
│                                                                                                                      │
│    938 │   │   │   response.drain_conn()                                                                             │
│    939 │   │   │   retries.sleep(response)                                                                           │
│    940 │   │   │   log.debug("Retry: %s", url)                                                                       │
│ ❱  941 │   │   │   return self.urlopen(                                                                              │
│    942 │   │   │   │   method,                                                                                       │
│    943 │   │   │   │   url,                                                                                          │
│    944 │   │   │   │   body,                                                                                         │
│                                                                                                                      │
│ C:\Users\enzoj\AppData\Local\Programs\Python\Python310\lib\site-packages\urllib3\connectionpool.py:941 in urlopen    │
│                                                                                                                      │
│    938 │   │   │   response.drain_conn()                                                                             │
│    939 │   │   │   retries.sleep(response)                                                                           │
│    940 │   │   │   log.debug("Retry: %s", url)                                                                       │
│ ❱  941 │   │   │   return self.urlopen(                                                                              │
│    942 │   │   │   │   method,                                                                                       │
│    943 │   │   │   │   url,                                                                                          │
│    944 │   │   │   │   body,                                                                                         │
│                                                                                                                      │
│ C:\Users\enzoj\AppData\Local\Programs\Python\Python310\lib\site-packages\urllib3\connectionpool.py:931 in urlopen    │
│                                                                                                                      │
│    928 │   │   has_retry_after = bool(response.headers.get("Retry-After"))                                           │
│    929 │   │   if retries.is_retry(method, response.status, has_retry_after):                                        │
│    930 │   │   │   try:                                                                                              │
│ ❱  931 │   │   │   │   retries = retries.increment(method, url, response=response, _pool=self)                       │
│    932 │   │   │   except MaxRetryError:                                                                             │
│    933 │   │   │   │   if retries.raise_on_status:                                                                   │
│    934 │   │   │   │   │   response.drain_conn()                                                                     │
│                                                                                                                      │
│ C:\Users\enzoj\AppData\Local\Programs\Python\Python310\lib\site-packages\urllib3\util\retry.py:515 in increment      │
│                                                                                                                      │
│   512 │   │                                                                                                          │
│   513 │   │   if new_retry.is_exhausted():                                                                           │
│   514 │   │   │   reason = error or ResponseError(cause)                                                             │
│ ❱ 515 │   │   │   raise MaxRetryError(_pool, url, reason) from reason  # type:                                       │
│       ignore[arg-type]                                                                                               │
│   516 │   │                                                                                                          │
│   517 │   │   log.debug("Incremented Retry for (url='%s'): %r", url, new_retry)                                      │
│   518                                                                                                                │
╰──────────────────────────────────────────────────────────────────────────────────────────────────────────────────────╯
MaxRetryError: HTTPSConnectionPool(host='api.spotify.com', port=443): Max retries exceeded with url:
/v1/albums/2Tmql4gLUk7LvmjeEgotxg (Caused by ResponseError('too many 429 error responses'))

During handling of the above exception, another exception occurred:

╭───────────────────────────────────────── Traceback (most recent call last) ──────────────────────────────────────────╮
│ C:\Users\enzoj\AppData\Local\Programs\Python\Python310\lib\site-packages\spotipy\client.py:266 in _internal_call     │
│                                                                                                                      │
│    263 │   │   │   │   │    method, url, args.get("params"), headers, args.get('data'))                              │
│    264 │   │                                                                                                         │
│    265 │   │   try:                                                                                                  │
│ ❱  266 │   │   │   response = self._session.request(                                                                 │
│    267 │   │   │   │   method, url, headers=headers, proxies=self.proxies,                                           │
│    268 │   │   │   │   timeout=self.requests_timeout, **args                                                         │
│    269 │   │   │   )                                                                                                 │
│                                                                                                                      │
│ C:\Users\enzoj\AppData\Local\Programs\Python\Python310\lib\site-packages\requests\sessions.py:589 in request         │
│                                                                                                                      │
│   586 │   │   │   "allow_redirects": allow_redirects,                                                                │
│   587 │   │   }                                                                                                      │
│   588 │   │   send_kwargs.update(settings)                                                                           │
│ ❱ 589 │   │   resp = self.send(prep, **send_kwargs)                                                                  │
│   590 │   │                                                                                                          │
│   591 │   │   return resp                                                                                            │
│   592                                                                                                                │
│                                                                                                                      │
│ C:\Users\enzoj\AppData\Local\Programs\Python\Python310\lib\site-packages\requests\sessions.py:703 in send            │
│                                                                                                                      │
│   700 │   │   start = preferred_clock()                                                                              │
│   701 │   │                                                                                                          │
│   702 │   │   # Send the request                                                                                     │
│ ❱ 703 │   │   r = adapter.send(request, **kwargs)                                                                    │
│   704 │   │                                                                                                          │
│   705 │   │   # Total elapsed time of the request (approximately)                                                    │
│   706 │   │   elapsed = preferred_clock() - start                                                                    │
│                                                                                                                      │
│ C:\Users\enzoj\AppData\Local\Programs\Python\Python310\lib\site-packages\requests\adapters.py:510 in send            │
│                                                                                                                      │
│   507 │   │   │   │   │   raise ConnectTimeout(e, request=request)                                                   │
│   508 │   │   │                                                                                                      │
│   509 │   │   │   if isinstance(e.reason, ResponseError):                                                            │
│ ❱ 510 │   │   │   │   raise RetryError(e, request=request)                                                           │
│   511 │   │   │                                                                                                      │
│   512 │   │   │   if isinstance(e.reason, _ProxyError):                                                              │
│   513 │   │   │   │   raise ProxyError(e, request=request)                                                           │
╰──────────────────────────────────────────────────────────────────────────────────────────────────────────────────────╯
RetryError: HTTPSConnectionPool(host='api.spotify.com', port=443): Max retries exceeded with url:
/v1/albums/2Tmql4gLUk7LvmjeEgotxg (Caused by ResponseError('too many 429 error responses'))

During handling of the above exception, another exception occurred:

╭───────────────────────────────────────── Traceback (most recent call last) ──────────────────────────────────────────╮
│ C:\Users\enzoj\AppData\Local\Programs\Python\Python310\lib\site-packages\spotdl\console\entry_point.py:124 in        │
│ console_entry_point                                                                                                  │
│                                                                                                                      │
│   121 │   try:                                                                                                       │
│   122 │   │   # Pick the operation to perform                                                                        │
│   123 │   │   # based on the name and run it!                                                                        │
│ ❱ 124 │   │   OPERATIONS[arguments.operation](                                                                       │
│   125 │   │   │   query=arguments.query,                                                                             │
│   126 │   │   │   downloader=downloader,                                                                             │
│   127 │   │   )                                                                                                      │
│                                                                                                                      │
│ C:\Users\enzoj\AppData\Local\Programs\Python\Python310\lib\site-packages\spotdl\console\sync.py:94 in sync           │
│                                                                                                                      │
│    91 │   │   │   raise ValueError("Sync file is not a valid sync file.")                                            │
│    92 │   │                                                                                                          │
│    93 │   │   # Parse the query                                                                                      │
│ ❱  94 │   │   songs_playlist = parse_query(sync_data["query"], downloader.settings["threads"])                       │
│    95 │   │                                                                                                          │
│    96 │   │   # Get the names and URLs of previously downloaded songs from the sync file                             │
│    97 │   │   old_files = []                                                                                         │
│                                                                                                                      │
│ C:\Users\enzoj\AppData\Local\Programs\Python\Python310\lib\site-packages\spotdl\utils\search.py:94 in parse_query    │
│                                                                                                                      │
│    91 │   - List of song objects                                                                                     │
│    92 │   """                                                                                                        │
│    93 │                                                                                                              │
│ ❱  94 │   songs: List[Song] = get_simple_songs(query, use_ytm_data=use_ytm_data)                                     │
│    95 │                                                                                                              │
│    96 │   results = []                                                                                               │
│    97 │   with concurrent.futures.ThreadPoolExecutor(max_workers=threads) as executor:                               │
│                                                                                                                      │
│ C:\Users\enzoj\AppData\Local\Programs\Python\Python310\lib\site-packages\spotdl\utils\search.py:230 in               │
│ get_simple_songs                                                                                                     │
│                                                                                                                      │
│   227 │   │   elif "open.spotify.com" in request and "album" in request:                                             │
│   228 │   │   │   lists.append(Album.from_url(request, fetch_songs=False))                                           │
│   229 │   │   elif "open.spotify.com" in request and "artist" in request:                                            │
│ ❱ 230 │   │   │   lists.append(Artist.from_url(request, fetch_songs=False))                                          │
│   231 │   │   elif "album:" in request:                                                                              │
│   232 │   │   │   lists.append(Album.from_search_term(request, fetch_songs=False))                                   │
│   233 │   │   elif "playlist:" in request:                                                                           │
│                                                                                                                      │
│ C:\Users\enzoj\AppData\Local\Programs\Python\Python310\lib\site-packages\spotdl\types\song.py:296 in from_url        │
│                                                                                                                      │
│   293 │   │   - The SongList object.                                                                                 │
│   294 │   │   """                                                                                                    │
│   295 │   │                                                                                                          │
│ ❱ 296 │   │   metadata, songs = cls.get_metadata(url)                                                                │
│   297 │   │   urls = [song.url for song in songs]                                                                    │
│   298 │   │                                                                                                          │
│   299 │   │   if fetch_songs:                                                                                        │
│                                                                                                                      │
│ C:\Users\enzoj\AppData\Local\Programs\Python\Python310\lib\site-packages\spotdl\types\artist.py:88 in get_metadata   │
│                                                                                                                      │
│    85 │   │                                                                                                          │
│    86 │   │   songs = []                                                                                             │
│    87 │   │   for album in albums:                                                                                   │
│ ❱  88 │   │   │   album_obj = Album.from_url(album, fetch_songs=False)                                               │
│    89 │   │   │   songs.extend(album_obj.songs)                                                                      │
│    90 │   │                                                                                                          │
│    91 │   │   # Very aggressive deduplication                                                                        │
│                                                                                                                      │
│ C:\Users\enzoj\AppData\Local\Programs\Python\Python310\lib\site-packages\spotdl\types\song.py:296 in from_url        │
│                                                                                                                      │
│   293 │   │   - The SongList object.                                                                                 │
│   294 │   │   """                                                                                                    │
│   295 │   │                                                                                                          │
│ ❱ 296 │   │   metadata, songs = cls.get_metadata(url)                                                                │
│   297 │   │   urls = [song.url for song in songs]                                                                    │
│   298 │   │                                                                                                          │
│   299 │   │   if fetch_songs:                                                                                        │
│                                                                                                                      │
│ C:\Users\enzoj\AppData\Local\Programs\Python\Python310\lib\site-packages\spotdl\types\album.py:42 in get_metadata    │
│                                                                                                                      │
│    39 │   │                                                                                                          │
│    40 │   │   spotify_client = SpotifyClient()                                                                       │
│    41 │   │                                                                                                          │
│ ❱  42 │   │   album_metadata = spotify_client.album(url)                                                             │
│    43 │   │   if album_metadata is None:                                                                             │
│    44 │   │   │   raise AlbumError(                                                                                  │
│    45 │   │   │   │   "Couldn't get metadata, check if you have passed correct album id"                             │
│                                                                                                                      │
│ C:\Users\enzoj\AppData\Local\Programs\Python\Python310\lib\site-packages\spotipy\client.py:461 in album              │
│                                                                                                                      │
│    458 │   │   if market is not None:                                                                                │
│    459 │   │   │   return self._get("albums/" + trid + '?market=' + market)                                          │
│    460 │   │   else:                                                                                                 │
│ ❱  461 │   │   │   return self._get("albums/" + trid)                                                                │
│    462 │                                                                                                             │
│    463 │   def album_tracks(self, album_id, limit=50, offset=0, market=None):                                        │
│    464 │   │   """ Get Spotify catalog information about an album's tracks                                           │
│                                                                                                                      │
│ C:\Users\enzoj\AppData\Local\Programs\Python\Python310\lib\site-packages\spotdl\utils\spotify.py:193 in _get         │
│                                                                                                                      │
│   190 │   │   retries = self.max_retries  # type: ignore # pylint: disable=E1101                                     │
│   191 │   │   while response is None:                                                                                │
│   192 │   │   │   try:                                                                                               │
│ ❱ 193 │   │   │   │   response = self._internal_call("GET", url, payload, kwargs)                                    │
│   194 │   │   │   except (requests.exceptions.Timeout, requests.ConnectionError) as exc:                             │
│   195 │   │   │   │   retries -= 1                                                                                   │
│   196 │   │   │   │   if retries <= 0:                                                                               │
│                                                                                                                      │
│ C:\Users\enzoj\AppData\Local\Programs\Python\Python310\lib\site-packages\spotipy\client.py:307 in _internal_call     │
│                                                                                                                      │
│    304 │   │   │   │   reason = retry_error.args[0].reason                                                           │
│    305 │   │   │   except (IndexError, AttributeError):                                                              │
│    306 │   │   │   │   reason = None                                                                                 │
│ ❱  307 │   │   │   raise SpotifyException(                                                                           │
│    308 │   │   │   │   429,                                                                                          │
│    309 │   │   │   │   -1,                                                                                           │
│    310 │   │   │   │   "%s:\n %s" % (request.path_url, "Max Retries"),                                               │
╰──────────────────────────────────────────────────────────────────────────────────────────────────────────────────────╯
SpotifyException: http status: 429, code:-1 - /v1/albums/2Tmql4gLUk7LvmjeEgotxg:
 Max Retries, reason: too many 429 error responses

Other details

No response

xnetcat commented 1 year ago

You are trying to download too much too fast. Try waiting and lower the number of threads.

enzomtpYT commented 1 year ago

i already tried to put 1 threads and restarting 1 day later, but the same error keeps happening

abcdefghijorngarbosaxyz commented 1 year ago

You're getting rate limited by Spotify. You can try manually splitting the spotdl sync file.

enzomtpYT commented 1 year ago

I tried to reduce the number of music to download (now arround 1600 instead of arround 20000), but the error keeps happening


Processing query: https://open.spotify.com/artist/53XhwfbYqKCa1cC15pYq2q
Processing query: https://open.spotify.com/playlist/4br15pxVuXjr4qU0KBfWMY
Processing query: https://open.spotify.com/playlist/37i9dQZF1DXblmY5UIU3v3
Processing query: https://open.spotify.com/playlist/2INV6A28riGzcxVbaGdFEj
Processing query: https://open.spotify.com/playlist/37i9dQZF1E4nPxD8D3A5X8
Processing query: https://open.spotify.com/artist/36JJbH66Q0tZbKcnjvliDT
Processing query: https://open.spotify.com/artist/3zYU33YUxJPzsPrYmpMMiu
Processing query: https://open.spotify.com/artist/3YJDqtTSjydvUpTvU1fJ6O
Processing query: https://open.spotify.com/playlist/49BVzg9khU4gahhXbyKQZM
Processing query: https://open.spotify.com/playlist/5f6QseEksL1FNFVzQcgJgC
Processing query: https://open.spotify.com/artist/6BxtVo9reMQ2vff0l8HMGY
Processing query: https://open.spotify.com/artist/1gmwm51vXSRWAt3J8bBdO3
Processing query: https://open.spotify.com/artist/5eYIGMKb2BdsIXbScrOPK2
Processing query: https://open.spotify.com/artist/2M1EOE4J6tnaLCfMhE3eFq
Processing query: https://open.spotify.com/playlist/1LdkJOaBVrlyf5F3oijXbF
Processing query: https://open.spotify.com/artist/5AqhBC5pt6b0WVpUAII1Ro
Processing query: https://open.spotify.com/playlist/2x5ST1hmLc8TjA1Ybp5Hh7
Processing query: https://open.spotify.com/playlist/09rQgqnmP26wLv7EK4GCwr
Processing query: https://open.spotify.com/playlist/4M5EDY72Y2RmljqZwrJVvE
Processing query: https://open.spotify.com/playlist/4kR9oczE6zpsg3OGeftphB
Processing query: https://open.spotify.com/playlist/0pwcV257JtjlsPZfccinrb
Processing query: https://open.spotify.com/playlist/12De0szTOpqk7brqebkjtl
Processing query: https://open.spotify.com/playlist/10qkoUHZdgMIkeWjjRLGrO
Processing query: https://open.spotify.com/playlist/4M2EwzhQSyLeWIWrXGuRjs
Processing query: https://open.spotify.com/playlist/6kFJZeMre5N7apwNAUjRiC
Processing query: https://open.spotify.com/playlist/2qKw3MEA349w9xrYOrzJQp
Processing query: https://open.spotify.com/artist/1T7zBkQCOCacKjbnmFX7cp
Found 243 songs in Imagine Dragons (Artist)
Found 58 songs in HARDCORE (Playlist)
Found 50 songs in DOWN LOW (Playlist)
Found 168 songs in Motivation (Playlist)
Found 50 songs in Mittsies Radio (Playlist)
Found 65 songs in Wubbaduck (Artist)
Found 15 songs in Aests (Artist)
Found 236 songs in CG5 (Artist)
Found 168 songs in BASSSSSSSSSSSSSSSS BROOOOO (Playlist)
Found 81 songs in Animations meme musics (Playlist)
Found 35 songs in Canonblade (Artist)
Found 17 songs in Dalux (Artist)
Found 13 songs in Exyl (Artist)
Found 29 songs in YonKaGor (Artist)
Found 9 songs in J'en ai pleuré (Playlist)
Found 19 songs in JOYCA (Artist)
Found 503 songs in Musique Aimé [Youtube] enzomtp (Playlist)
Found 230 songs in Aggresive (Playlist)
Found 47 songs in ChinaTown (Playlist)
Found 12 songs in Only good vibes (Playlist)
Found 10 songs in Cyber (Playlist)
Found 22 songs in Virtual Riot - Idols (Song List) (Playlist)
Found 19 songs in Motivation But Its anime (Playlist)
Found 194 songs in Gaming Music 2023 🎮 Best Gaming Mix (Playlist)
Found 13 songs in Trends (Playlist)
Found 35 songs in Asphalt 9 (Playlist)
Found 1162 songs in GameChops (Artist)
Max Retries reached
Takanori Nishikawa - Roll The Dice (「Thunderbolt Fantasy 東離劍遊紀2」ED ver.) generated an exception: http status: 429, code:-1 -
/v1/artists/2ayMogRmamCnzMAk4YiFAz:
 Max Retries, reason: too many 429 error responses

An error occurred
╭───────────────────────────────────────────────── Traceback (most recent call last) ──────────────────────────────────────────────────╮
│ C:\Users\enzoj\AppData\Local\Programs\Python\Python310\lib\site-packages\spotdl\console\entry_point.py:124 in console_entry_point    │
│                                                                                                                                      │
│   121 │   try:                                                                                                                       │
│   122 │   │   # Pick the operation to perform                                                                                        │
│   123 │   │   # based on the name and run it!                                                                                        │
│ ❱ 124 │   │   OPERATIONS[arguments.operation](                                                                                       │
│   125 │   │   │   query=arguments.query,                                                                                             │
│   126 │   │   │   downloader=downloader,                                                                                             │
│   127 │   │   )                                                                                                                      │
│                                                                                                                                      │
│ C:\Users\enzoj\AppData\Local\Programs\Python\Python310\lib\site-packages\spotdl\console\sync.py:98 in sync                           │
│                                                                                                                                      │
│    95 │   │                                                                                                                          │
│    96 │   │   # Get the names and URLs of previously downloaded songs from the sync file                                             │
│    97 │   │   old_files = []                                                                                                         │
│ ❱  98 │   │   for entry in sync_data["songs"]:                                                                                       │
│    99 │   │   │   file_name = create_file_name(                                                                                      │
│   100 │   │   │   │   Song.from_dict(entry),                                                                                         │
│   101 │   │   │   │   downloader.settings["output"],                                                                                 │
╰──────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────╯
KeyError: 'songs'```
xnetcat commented 1 year ago

you've malformed your sync file, i've added a check so that spotdl won't crash again but your sync file still won't work. try making few smaller playlists.

Loudic85 commented 3 months ago

I have this error also but i have only 61 songs to download...

Here the log in console :

Max Retries reached INFO: ::1:38676 - "GET /api/url?url=https:%2F%2Fopen.spotify.com%2Fplaylist%2F0MbATxbOCwGz3RTq3IaIyP HTTP/1.1" 500 Internal Server Error ERROR: Exception in ASGI application urllib3.exceptions.ResponseError: too many 429 error responses

The above exception was the direct cause of the following exception:

Traceback (most recent call last): File "requests\adapters.py", line 486, in send File "urllib3\connectionpool.py", line 948, in urlopen File "urllib3\connectionpool.py", line 948, in urlopen File "urllib3\connectionpool.py", line 948, in urlopen File "urllib3\connectionpool.py", line 938, in urlopen File "urllib3\util\retry.py", line 515, in increment urllib3.exceptions.MaxRetryError: HTTPSConnectionPool(host='api.spotify.com', port=443): Max retries exceeded with url: /v1/tracks/4UDmDIqJIbrW0hMBQMFOsM (Caused by ResponseError('too many 429 error responses'))

During handling of the above exception, another exception occurred:

Traceback (most recent call last): File "spotipy\client.py", line 266, in _internal_call File "requests\sessions.py", line 589, in request File "requests\sessions.py", line 703, in send File "requests\adapters.py", line 510, in send requests.exceptions.RetryError: HTTPSConnectionPool(host='api.spotify.com', port=443): Max retries exceeded with url: /v1/tracks/4UDmDIqJIbrW0hMBQMFOsM (Caused by ResponseError('too many 429 error responses'))

During handling of the above exception, another exception occurred:

Traceback (most recent call last): File "uvicorn\protocols\http\h11_impl.py", line 408, in run_asgi File "uvicorn\middleware\proxy_headers.py", line 84, in call File "fastapi\applications.py", line 292, in call File "starlette\applications.py", line 122, in call File "starlette\middleware\errors.py", line 184, in call File "starlette\middleware\errors.py", line 162, in call File "starlette\middleware\cors.py", line 83, in call File "starlette\middleware\exceptions.py", line 79, in call File "starlette\middleware\exceptions.py", line 68, in call File "fastapi\middleware\asyncexitstack.py", line 20, in call File "fastapi\middleware\asyncexitstack.py", line 17, in call File "starlette\routing.py", line 718, in call File "starlette\routing.py", line 276, in handle File "starlette\routing.py", line 66, in app File "fastapi\routing.py", line 273, in app File "fastapi\routing.py", line 192, in run_endpoint_function File "starlette\concurrency.py", line 41, in run_in_threadpool File "anyio\to_thread.py", line 33, in run_sync File "anyio_backends_asyncio.py", line 877, in run_sync_in_worker_thread File "anyio_backends_asyncio.py", line 807, in run File "spotdl\utils\web.py", line 315, in songs_from_url File "spotdl\types\song.py", line 310, in from_url File "spotdl\types\song.py", line 310, in File "spotdl\types\song.py", line 84, in from_url File "spotipy\client.py", line 371, in track File "spotdl\utils\spotify.py", line 195, in _get File "spotipy\client.py", line 307, in _internal_call spotipy.exceptions.SpotifyException: http status: 429, code:-1 - /v1/tracks/4UDmDIqJIbrW0hMBQMFOsM: Max Retries, reason: too many 429 error responses