aome510 / spotify-player

A Spotify player in the terminal with full feature parity
MIT License
3.65k stars 166 forks source link

Spotify session randomly invalidated #579

Closed apprehensions closed 1 month ago

apprehensions commented 1 month ago

Describe the bug While i sit on my chair, enjoying my music, i suddenly realize that the music stopped, with no clear indication as to why, and i am forced to replay the same song, knowing it will never hit the same again, because it was interrupted.

To Reproduce Play music.

Expected behaviour I continue hearing the music

Log and backtrace

2024-10-16T12:08:49.080339Z  INFO spotify_player::streaming: Got a new player event: Changed { old_track_id: TrackId("6vMib26W91Ue1PbFilnJfu"), new_track_id: TrackId("4x6duj3S7xHFhEUfDSbWgQ") }
2024-10-16T12:08:50.215753Z  INFO spotify_player::streaming: Got a new player event: Playing { track_id: TrackId("4x6duj3S7xHFhEUfDSbWgQ"), position_ms: 0, duration_ms: 892853 }
2024-10-16T12:08:51.025125Z  INFO client_request{request=GetCurrentUserQueue}: spotify_player::client: Successfully handled the client request, took: 575ms
2024-10-16T12:19:57.181822Z  INFO spotify_player::client: Client's current session is invalid, creating a new session...
2024-10-16T12:19:57.926983Z  INFO spotify_player::auth: Successfully used the cached credentials to create a new session!
2024-10-16T12:19:57.927140Z  INFO spotify_player::client: Used a new session for Spotify client.

Environment

Additional context It happened again as i was making this issue.

aome510 commented 1 month ago

I also encounter a similar issue occasionally in my company. My first impression is because of unstable network but haven't really investigated it further.

apprehensions commented 1 month ago

I also figured it was due to WI-FI issues, so i've disabled it and switched to Ethernet, and it still occurs.

aome510 commented 1 month ago

interesting, good to know

apprehensions commented 1 month ago

I can't take it anymore. It stopped as soon as the best part of a song began.

TheGassyNinja commented 1 month ago

I have been having the same issue for a couple of weeks. Same log output error as Apprehensions (OP)

diegoulloao commented 1 month ago

Having the same issue right now, has been happening since the last week and now it happened after only 45s of listening.

aome510 commented 1 month ago

Possibly related: https://github.com/librespot-org/librespot/discussions/609. I will need to do some monitoring to see if it's the same issue. It seems to happen more often now compared to the past.

aome510 commented 1 month ago

I'm pretty sure it's https://github.com/librespot-org/librespot/issues/1340 after some monitoring and look like it is resolved in 0.5.0 release!