Skip to content

Commit dfd1815

Browse files
committed
chore(call): suppress mpg123 buffer underflow warnings in npm run call
The `speaker` npm package delegates to mpg123/coreaudio on macOS, which writes `Didn't have any audio data in callback (buffer underflow)` lines directly to stderr from native C code whenever the playback queue briefly empties between WebSocket audio chunks. These are normal operational noise (not errors) but can dominate the CLI output 3-15 times per call. Wrap the `call` script with `bash -c` + a stderr process substitution filter that drops any line containing "buffer underflow". The wrapper uses `exec` so signals (Ctrl+C) pass through unchanged to tsx. bash is invoked explicitly so the filter works regardless of npm's default script-shell (sh/dash on some Linux distros doesn't support process substitution). Only affects the `npm run call` CLI — no runtime behavior change for the voice agent or any other command. Every downstream customer clone of this template benefits automatically.
1 parent e210277 commit dfd1815

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@
1010
"apply": "tsx src/apply-cmd.ts",
1111
"push": "tsx src/push-cmd.ts",
1212
"pull": "tsx src/pull-cmd.ts",
13-
"call": "tsx src/call-cmd.ts",
13+
"call": "bash -c 'exec tsx src/call-cmd.ts \"$@\" 2> >(grep --line-buffered -v \"buffer underflow\" >&2)' --",
1414
"cleanup": "tsx src/cleanup-cmd.ts",
1515
"eval": "tsx src/eval.ts",
1616
"build": "tsc --noEmit",

0 commit comments

Comments
 (0)