Repository navigation
Conversation
|
This PR doesn't fully meet our contributing guidelines and PR template. What needs to be fixed:
Please edit this PR description to address the above within 2 hours, or it will be automatically closed. If you believe this was flagged incorrectly, please let a maintainer know. |
|
The following comment was made by an LLM, it may be inaccurate: |
|
End-to-end evidence on an audio-less aarch64 Linux host, playing a real bundled mp3 through the TUI audio path: Before (dev audio.ts): 36 lines of ALSA diagnostics on stderr, same signature as #41763 (cannot find card '0' ... Unknown PCM default), then start fails with status -5. Note: full bun test suite and typecheck still need a complete dependency install; the new audio-device.test.ts was verified standalone (5/5) since @OpenTui packages came out of bun install missing their root files in this environment (repaired locally from a clean fetch, unrelated to this diff). |
|
This pull request has been automatically closed because it was not updated to meet our contributing guidelines within the 2-hour window. Feel free to open a new pull request that follows our guidelines. |
Issue for this PR
Closes #41763
Type of change
What does this PR do?
On Linux hosts without an audio playback device (Termux/Android, soundless servers), any attention sound makes the native backend print ALSA diagnostics to stderr, overwriting the TUI.
I added a probe (new
packages/tui/src/audio-device.ts) that looks for a PCM playback node under /dev/snd beforeAudio.createruns. If none exists, audio is skipped with a debug line and nothing touches the native backend. Non-Linux behavior is unchanged, and nothing changes when a device is present. The notification leg ofattention.notifyis untouched — only the sound leg can now come back false early.How did you verify your code works?
packages/tui/test/audio-device.test.ts: playback detect, capture/mixer-only reject, unreadable /dev/snd, non-Linux skip — 5/5 standalone.Screenshots / recordings
Not a UI change — the fix removes stray stderr text. No screenshot applies.
Checklist