Improve huddle audio failure handling#2578
Conversation
|
I think failed starts can leave a phantom active huddle for other or reloaded clients. This looks adjacent and pre-existing rather than introduced by the formatter, but this PR's target failure mode exercises it directly. Could we publish an ended event during rollback, or otherwise make rollback observable to lifecycle reconstruction, and cover start → rollback reconstruction? |
I went ahead now and improve huddle audio failure handling. |
## Buzz Desktop release v0.4.25 ### Changes since v0.4.24: - fix(discovery): spawn PowerShell install commands natively on Windows ([#2750](#2750)) ([`f3981dbfe`](f3981db)) - fix(desktop): use augmented PATH for model discovery subprocess ([#2753](#2753)) ([`3bd3a014c`](3bd3a01)) - Improve huddle audio failure handling ([#2578](#2578)) ([`fb4a801ad`](fb4a801)) - fix(onboarding): show real install errors and fix concurrent install state ([#2658](#2658)) ([`9731cd818`](9731cd8)) - feat(node): add Windows managed Node.js fallback (win-x64 + win-arm64) ([#2661](#2661)) ([`596386ee5`](596386e)) - fix(desktop): parse runtime team instructions section ([#2645](#2645)) ([`269ef357f`](269ef35)) - Match create-channel template selector styling ([#2654](#2654)) ([`72bbaece4`](72bbaec)) - feat(desktop): make pull request reviews actionable ([#2510](#2510)) ([`9081ab0ec`](9081ab0)) - fix(desktop): shared-compute usability — share toggle, usage indicator, model resync ([#2448](#2448)) ([`9cc9652c7`](9cc9652)) - fix(desktop): refine focused thread dismissal targets ([#2644](#2644)) ([`c86c4f59c`](c86c4f5)) - Clarify agent harness defaults in create flow ([#2601](#2601)) ([`76aeae703`](76aeae7)) - fix: expose community icon control on open relays ([#2640](#2640)) ([`e341b09cb`](e341b09)) **To release:** merge this PR. The tag and build will happen automatically.
Summary
Behavior
The Tauri huddle commands reject with a plain string. Several desktop toast call sites only preserved JavaScript
Errorobjects, so the relay message was discarded and replaced with “Failed to join huddle.”The desktop now recognizes
huddle_audio_unavailableand the current relay message, then shows:Other relay and device messages remain intact, including microphone errors.
start_huddlealso publishesKIND_HUDDLE_STARTEDbefore audio setup. If setup fails, rollback now publishesKIND_HUDDLE_ENDEDthrough the normal end-and-archive path before resetting local state. This makes the failed start observable to lifecycle reconstruction and prevents stale join affordances.Checks
cd desktop && pnpm test— 3,405 passedcd desktop/src-tauri && cargo test— 1,560 passed, 13 ignored; 3 diagnostic tests passedcd desktop && pnpm exec playwright test tests/e2e/channels.spec.ts --project=smoke --grep 'huddle rollback end event'— passedjust desktop-tauri-checkcd desktop && pnpm typecheckcd desktop && pnpm check