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

Spotify network error narrowcasting #926

Open
supertom01 opened this issue Feb 4, 2025 · 2 comments · Fixed by #933 · May be fixed by #934
Open

Spotify network error narrowcasting #926

supertom01 opened this issue Feb 4, 2025 · 2 comments · Fixed by #933 · May be fixed by #934
Assignees

Comments

@supertom01
Copy link
Member

The updating of the Spotify status for narrowcasting tends to break quite often. Since the connection is sometimes blocked. Instead of breaking the webserver, it is better to just ignore it, since it happens rather often. Or to still fail, but not that aggressively (since if Spotify is actually down we do want to know)

The error originates here:  File "./amelie/narrowcasting/views.py", line 123, in room_spotify_now_playing
    res = requests.get("https://api.spotify.com/v1/me/player",

Exception Type: ConnectionError at /narrowcasting/room/spotify/
Exception Value: HTTPSConnectionPool(host='api.spotify.com', port=443): Max retries exceeded

@supertom01 supertom01 moved this from Backlog to Ready in WWW - Sprint board Feb 4, 2025
@Berehum Berehum moved this from Ready to In progress in WWW - Sprint board Feb 4, 2025
@Berehum
Copy link
Contributor

Berehum commented Feb 4, 2025

@supertom01 Would this help? It should already catch the exceptions, so I've changed it to just print the type of error instead of also providing specifics.

@supertom01 supertom01 self-assigned this Mar 3, 2025
@supertom01 supertom01 linked a pull request Mar 3, 2025 that will close this issue
@supertom01 supertom01 moved this from In progress to In review in WWW - Sprint board Mar 3, 2025
@github-project-automation github-project-automation bot moved this from In review to Done in WWW - Sprint board Mar 3, 2025
@supertom01
Copy link
Member Author

Seems that catching the union of two exceptions goes wrong, so reopening for a fix

@supertom01 supertom01 reopened this Mar 4, 2025
@supertom01 supertom01 moved this from Done to In review in WWW - Sprint board Mar 4, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
Status: In review
2 participants