zotify-dev / zotify

A fast and customizable music and podcast downloader.
zlib License
1.22k stars 92 forks source link

Download issues #161

Closed Bergene closed 4 months ago

Bergene commented 4 months ago

Hi,

Whenever I try to download either an artist, album or track I now get an error.

For artists I getthis error:

Spotify API Error (try 1) (400): Bad Request Spotify API Error (400): Bad Request Traceback (most recent call last): File "/home/pi/.local/bin/zotify", line 8, in sys.exit(main()) File "/home/pi/.local/share/pipx/venvs/zotify/lib/python3.9/site-packages/zotify/main.py", line 64, in main args.func(args) File "/home/pi/.local/share/pipx/venvs/zotify/lib/python3.9/site-packages/zotify/app.py", line 48, in client download_from_urls(args.urls) File "/home/pi/.local/share/pipx/venvs/zotify/lib/python3.9/site-packages/zotify/app.py", line 97, in download_from_urls download_artist_albums(artist_id) File "/home/pi/.local/share/pipx/venvs/zotify/lib/python3.9/site-packages/zotify/album.py", line 56, in download_artist_albums albums = get_artist_albums(artist) File "/home/pi/.local/share/pipx/venvs/zotify/lib/python3.9/site-packages/zotify/album.py", line 37, in get_artist_albums album_ids = [resp[ITEMS][i][ID] for i in range(len(resp[ITEMS]))] KeyError: 'items'

It is generally the same error for all, either "Bad request" or some form of "Failed to query metadata".

Am I doing something wrong? I checked and it does not seem my account is banned.

Edit: May I add, it has worked flawlessly the past few weeks. The issue suddenly pooped up today in the middle of download an artist. On the last album it failed, I re-ran it and it worked (I still got the "Bad request" error, but it downloaded fine). After this nothing works. I have tried with artists I have previously downloaded as well, nothing.

amTresen commented 4 months ago

I have had this since today, too. I guess there has been an update to the Spotify API and we'll have to wait for an update for Zotify to work again.

whoshoe commented 4 months ago

Can confirm this only happened an hour ago.

Bergene commented 4 months ago

That was what I feared. Thank you for confirming, guys.

arkeence commented 4 months ago

I get

Invalid response from TRACKS_URL:
{"error": {"status": 400, "message": "Bad Request" } }

Traceback (most recent call last):
  File "C:\Users\R\pipx\venvs\zotify\Lib\site-packages\zotify\track.py", line 158, in download_track
    track_number, scraped_song_id, is_playable, duration_ms) = get_song_info(track_id)
                                                               ^^^^^^^^^^^^^^^^^^^^^^^
  File "C:\Users\R\pipx\venvs\zotify\Lib\site-packages\zotify\track.py", line 55, in get_song_info
    raise ValueError(f'Invalid response from TRACKS_URL:\n{raw}')
ValueError: Invalid response from TRACKS_URL:
{"error": {"status": 400, "message": "Bad Request" } }
Bergene commented 4 months ago

I see the API issues are affecting all endpoints except "me/player", according to users on isdown.app.

I tested the API on spotify's own API page and it returns the same error there.

steva22 commented 4 months ago

me too i have the same problem right now.

Bergene commented 4 months ago

It's working again now. It was probably a hickup on Spotify's API side.

arkeence commented 4 months ago

It's still not working. I get this when i try to download

Tzanca Uraganu - Emirate: 100%|██████████████████████████████████████████████████▉| 2.33M/2.33M [00:00<00:00, 2.65MB/s]
Spotify API Error (unknown): received an empty response
###   Skipping lyrics for Tzanca Uraganu - Emirate: lyrics not available   ###
Bergene commented 4 months ago

It works for me... Hope it works for you as well now after waiting a bit.