Closed Spaghet4Life closed 3 hours ago
Alright I figured out I needed to remove the <> from around the id, but now it's giving me a different error:
Traceback (most recent call last):
File "spotipy\oauth2.py", line 923, in get_access_token
File "requests\models.py", line 1021, in raise_for_status
requests.exceptions.HTTPError: 400 Client Error: Bad Request for url: https://accounts.spotify.com/api/token
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "main.py", line 4, in <module>
File "gui.py", line 41, in __init__
File "spotify_client.py", line 15, in create_spotify_client
File "spotipy\oauth2.py", line 929, in get_access_token
File "spotipy\oauth2.py", line 146, in _handle_oauth_error
spotipy.oauth2.SpotifyOauthError: error: invalid_client, error_description: Invalid client
This happens both on the app and on the web player.
Can you show what's inside your settings.ini file? You can include the client id its not sensitive info but if you don't want to just delete some random characters from it
Here's my settings.ini file:
[theme] ; available themes: https://ttkbootstrap.readthedocs.io/en/latest/themes/ theme = cyborg
[spotify] client_id = f9519738aec64ab5ac6d3a992eed328a redirect_uri = http://localhost:8888/callback
[lyrics] empty_lyric_replacement = ♫
That's weird, I can't replicate this error. In fact, when I try using your client id I can authenticate without any issues. After that it crashes because my spotify account isn't registered on your app, but the step that's failing for you isn't failing for me. I don't know if its an issue with the spotify api wrapper I'm using, I'll have to come back to this later on, but for now I'll try to add a workaround so that you can use the app 👍
My mom acrually got a premium duo plan out of nowhere the other day so I don't need the app anymore, don't worry about the workaround. Thank you anyways, good luck on fixing the issue!
I'll add the workaround anyway if anyone has the same issue lol but good for you :)
Wait did you maybe copy your client secret instead of your client id? If so that explains it, but also please change it asap in the dashboard as that is sensitive info
Also another thing you can try is deleting the .cache
file and trying again
If none of that works, as of v0.6.0 you can also authenticate the app using your client secret.
Just copy your client secret from the same page where you got your client id and add it to the settings.ini
file in front of client_secret =
[!CAUTION] Your client secret is very sensitive information and you should be very careful with it, so only do this if the other options fail 👍
Also I still haven't been able to replicate the error so I'm not 100% sure this will fix the issue. I'll close it for now but if anyone runs into this again please comment here :)
Describe the bug I found and set my client ID in the settings.ini file, but when I run the exe this tab opens in my browser (Firefox): "https://accounts.spotify.com/authorize?client_id=<my client id here, don't know if it's dangerous to share>&response_type=code&redirect_uri=http%3A%2F%2Flocalhost%3A8888%2Fcallback&code_challenge_method=S256&code_challenge=CpfoBs8911s7h-Jbmh-n3P8WXaDe9Wyor1wMJgnVdKA&scope=user-read-currently-playing"
which displays in plain text: "INVALID_CLIENT: Invalid client".
Nothing else happens.
Expected behavior The app opens and works as expected.
Real behavior The app doesn't open.
To Reproduce List the steps needed to reproduce the bug:
Context/Environment Write here the information about the environment in which the bug happens, such as:
Screenshots If applicable, add screenshots to help explain your problem.
Additional context I am using Firefox and a cracked Spotify client (BlockTheSpot), but it also doesn't seem to work if I have the web player open.