Only default device appears in output device list if squeezelite is set to auto run but fails to run
Nessuno ha ancora preso questa issue.
Valutazione
- Difficoltà
- 2/5
- Tempo stimato
- 1-3 ore
- Idoneità per principianti
- 52/100
Direzione di ricerca
Start in LocalPlayer/Settings.pm at handler2 around line 89, then read the Squeezelite devices routine and the nearby binary-path handling. Verify the behavior when autorun is enabled but Squeezelite fails to start; done means the output device list still includes available devices rather than only the default entry, with the relevant platform and Docker paths considered.
Scritto dal modello di indicizzazione a partire dal testo della issue.
Descrizione
Issue was discussed in this thread.
https://forums.lyrion.org/forum/user-forums/logitech-media-server/1785058-local-player-and-rpi-os-bookworm-desktop
From my posty on the thread. My understanding of the problem and a suggested fix.
The list of available output devices is generated by the devices routine in Settings.pm.
This routine can have one optional parameter - the path of the squeezelite binary to run.
If the squeezelite binary path is not supplied (as when called by handler2 in Settings.pm) and "autorun" pref is set, then the devices routine will use the path of the squeezelite that is running.
However if squeezelite has failed to run (e.g. output device inacessible/invalid), then devices routine has no path to binary and so returns a list just with "default" entry.
My suggested fix is to add the path to the devices call in Settings.pm handler2.
Line 89 LocalPlayer/Settings.pm
from
my $devices = Plugins::LocalPlayer::Squeezelite->devices;
to
my $devices = Plugins::LocalPlayer::Squeezelite->devices(Slim::Utils::Misc::findbin($bin));
Within the plugin, the determination of which version of squeezelite to run is a bit convoluted (e.g. OS / arch / Docker / pcp) , so I'm not 100% confident this will work for all instances.
However since Slim::Utils::Misc::findbin($bin) is used just a few lines above my changes to determine squeezelite command line options - I think it should be ok.
If it looks to be a fix there are efficiencies and tests that can be added to make it more robust.
- Lingua principale
- Perl
- Stelle
- 4
- Fork
- 5
- Metriche di merge delle PR
- Nessuna PR unita negli ultimi 30g
Guida per i contributori
Nessuna guida per i contributori indicizzata per questo repository
Come iniziare
- Leggi tutta la issue e poi la guida ai contributi del progetto.
- Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
- Fai un fork del repository e lavora su un branch.
- Apri una pull request che faccia riferimento al numero della issue.
Altre issue di LMS-Community/plugin-LocalPlayer
-
Installed in Docker Aperta
Difficoltà 5/5 Più di una settimana Idoneità per principianti 20/100
LMS-Community/plugin-LocalPlayer#2 · 1 commento ·
-
Difficoltà 4/5 3-5 giorni Idoneità per principianti 20/100
LMS-Community/plugin-LocalPlayer#1 · 5 commenti ·
Tutte le issue di LMS-Community/plugin-LocalPlayer
Issue simili
-
documentation Needs Triage
Difficoltà 2/5 1-3 ore Idoneità per principianti 75/100
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 75/100
trizen/youtube-viewer#456 ·
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 70/100
-
connectivity Aperta
Difficoltà 1/5 Meno di un'ora Idoneità per principianti 80/100
-
Common US ingredient names are not recognized, so about 12.4k US products miss an allergen warning Aperta
Difficoltà 2/5 1-3 ore Idoneità per principianti 75/100
openfoodfacts/openfoodfacts-server#14657 · 4 commenti ·