mirror of
https://github.com/librespot-org/librespot.git
synced 2026-04-27 16:25:52 +03:00
[GH-ISSUE #1389] Session expires: PermissionDenied, error: StatusCode(403) #626
Labels
No labels
A-Alsa
SpotifyAPI
Tokio 1.0
audio
bug
can't reproduce
compilation
dependencies
duplicate
enhancement
good first issue
help wanted
high priority
imported
imported
invalid
new api
pull-request
question
reverse engineering
wiki
wontfix
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
starred/librespot#626
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Originally created by @abrakadabra2k on GitHub (Nov 1, 2024).
Original GitHub issue: https://github.com/librespot-org/librespot/issues/1389
Description
After a random time period (around 1 hour, but not exactly 1h like in 1377 ) no music is played anymore. It seems this is happening after a Token expiration event.
After restarting librespot, everything is working fine
Version
0.5.0
How to reproduce
Running librespot in Moode's default settings
That should mean librespot is running with authentication via SpotifyConnect (started on an Android device).
[2024-11-01T13:46:27Z TRACE librespot] Command line argument(s):
[2024-11-01T13:46:27Z TRACE librespot] name "ServerMoode Spotify"
[2024-11-01T13:46:27Z TRACE librespot] bitrate "320"
[2024-11-01T13:46:27Z TRACE librespot] format "S16"
[2024-11-01T13:46:27Z TRACE librespot] mixer "softvol"
[2024-11-01T13:46:27Z TRACE librespot] initial-volume "100"
[2024-11-01T13:46:27Z TRACE librespot] volume-ctrl "log"
[2024-11-01T13:46:27Z TRACE librespot] volume-range "60"
[2024-11-01T13:46:27Z TRACE librespot] cache "/var/local/www/spotify_cache"
[2024-11-01T13:46:27Z TRACE librespot] disable-audio-cache
[2024-11-01T13:46:27Z TRACE librespot] backend "alsa"
[2024-11-01T13:46:27Z TRACE librespot] device "plughw:Loopback,0"
[2024-11-01T13:46:27Z TRACE librespot] onevent "/var/local/www/commandw/spotevent.sh"
[2024-11-01T13:46:27Z TRACE librespot] v
I have a couple of devices running the spotify client. It seems my Echo Dot takes over the client role frequently:
Line 34927: [2024-11-01T11:54:50Z DEBUG librespot_playback::player] command=EmitSessionClientChangedEvent("9a8d2f0ce77a4e248bb71fefcb557637", "Pixel 6a", "google", "Pixel 6a") Line 35286: [2024-11-01T11:54:51Z DEBUG librespot_playback::player] command=EmitSessionClientChangedEvent("27d4dfe427b34d57995b463e5d63198d", "db51dfff-8c44-4a27-83d9-18be1dc34854", "Amazon", "Echo_Dot") Line 40554: [2024-11-01T12:07:09Z DEBUG librespot_playback::player] command=EmitSessionClientChangedEvent("756a522d9f1648b89e76e80be654456a", "Grundig Android TV", "ARCELIK", "GrundigAndroidTV") Line 45366: [2024-11-01T12:21:07Z DEBUG librespot_playback::player] command=EmitSessionClientChangedEvent("9a8d2f0ce77a4e248bb71fefcb557637", "Pixel 6a", "google", "Pixel 6a") Line 45725: [2024-11-01T12:21:08Z DEBUG librespot_playback::player] command=EmitSessionClientChangedEvent("27d4dfe427b34d57995b463e5d63198d", "db51dfff-8c44-4a27-83d9-18be1dc34854", "Amazon", "Echo_Dot") Line 52288: [2024-11-01T12:39:43Z DEBUG librespot_playback::player] command=EmitSessionClientChangedEvent("9a8d2f0ce77a4e248bb71fefcb557637", "Pixel 6a", "google", "Pixel 6a") Line 52648: [2024-11-01T12:39:44Z DEBUG librespot_playback::player] command=EmitSessionClientChangedEvent("27d4dfe427b34d57995b463e5d63198d", "db51dfff-8c44-4a27-83d9-18be1dc34854", "Amazon", "Echo_Dot") Line 58873: [2024-11-01T13:10:05Z DEBUG librespot_playback::player] command=EmitSessionClientChangedEvent("756a522d9f1648b89e76e80be654456a", "Fire TV", "Amazon", "AFTKA") Line 59309: [2024-11-01T13:15:50Z DEBUG librespot_playback::player] command=EmitSessionClientChangedEvent("9a8d2f0ce77a4e248bb71fefcb557637", "Pixel 6a", "google", "Pixel 6a") Line 59669: [2024-11-01T13:15:50Z DEBUG librespot_playback::player] command=EmitSessionClientChangedEvent("27d4dfe427b34d57995b463e5d63198d", "db51dfff-8c44-4a27-83d9-18be1dc34854", "Amazon", "Echo_Dot")So far, this has been happening in every session.
Log
see for exact position of error https://pastebin.com/aLck4imV
Host (what you are running
librespoton):running on Moode 9.1.4 with Raspberry Pi 4 (multiroom mode, but that should not matter)
Additional context
Android device (Pixel 6a) shows still the librespot device as "connected"
@roderickvd commented on GitHub (Nov 1, 2024):
Please try with 0.6.0 that was released days ago.
@kingosticks commented on GitHub (Nov 1, 2024):
We should fix these logs to redact the tokens.
@abrakadabra2k commented on GitHub (Nov 3, 2024):
It seems the issue is solved with 0.6.0
24hours uninterrupted playback. This was never achieved with previous versions on my setup