Closed jlehtoranta closed 1 year ago
Sorry for the delay, this looks like a good catch and neat implementation. Would you add a changelog entry for this fix? Looks good to merge after!
Kind nudge to @jlehtoranta - could you add a changelog entry so we can merge this?
Kind nudge to @jlehtoranta - could you add a changelog entry so we can merge this?
Thanks for your comments and sorry for the delay. This is now rebased and a changelog entry has been added. I added it under "Changed", since this is more of a behaviour change rather than a simple bug fix
Excellent, thank you very much.
I'm not sure whether that was intended, but it appears that this PR improved connection stability slightly (see https://github.com/Spotifyd/spotifyd/issues/1211 for details) so thanks for that :)
Create a single player instance, when librespot starts and keep it running over reconnections. In the current implementation the player is recreated on every reconnection, which causes the output device to be recreated too. This creates a racing condition in Jack, which occasionally causes the output device to be created with a different name. This is an issue especially when using Jack's custom routing. I.e. A different user connects via Spotify Connect and Jack doesn't create the configured audio route because of the name change.