Repository navigation
v0.5.1 — the control API could be killed by regenerating its own key
Pressing Regenerate on the API key restarted the listener on the same port, and Server::drop returned without waiting for the accept thread to exit — so the old socket was still open when the new bind ran. Address already in use, and the control API stayed dead until the app was restarted. Drop now joins the thread.
GET /api/status reports pid, so a caller can act on that process instead of searching by name.
handover.sh no longer uses pgrep: it matches by name across the whole machine, so it escaped a private D-Bus session and a private config directory and SIGTERMed the real player mid-song. The outgoing pid now comes from the API's pid or from the bus, both scoped to the instance being handed over — and it refuses rather than guessing. It also gained an MPRIS fallback, so a player whose API is down can still be swapped without stopping the music (49 ms), and it keeps the replacement's stderr.
Scripts that touch the desktop are gated on the machine being idle via xprintidle: verify-input.sh will not run at all without GAPLESS_INPUT_OK=1 and abandons its run the instant a real keypress arrives; verify-api.sh and verify-mpris-modes.sh wait for a free desk before opening a window. verify.sh and verify-resume.sh touch nothing.