fondberg / spotcast

Home assistant custom component to start Spotify playback on an idle chromecast device as well as control spotify connect devices
Apache License 2.0
672 stars 96 forks source link

Check for 302 status with a redirect to &_authfailed=1 in token request #408

Closed Gramatus closed 9 months ago

Gramatus commented 1 year ago

My cookies was expired, and I noticed that this time, it was not caught by the except TooManyRedirects: catch block. However, the logs gave me just info that we had a 302 response. I found that this response had a Location-header pointing to /get_access_token?reason=transport&productType=web_player&_authfailed=1. I figured it would be useful to check for this and give some more errors in the logs.