Nuggets workflow audio: include failure reason in the error message; v2.17.2
Publish Container / build (push) Successful in 15m27s

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
This commit is contained in:
nmemmertandClaude Sonnet 5.5 committed 2026-10-12 09:38:17 -04:00
1 parent 11f3d76e9b
commit 22c0038ebb
3 files changed
+6 -4

No files matched your search

+3 -1
View File
@@ -139,7 +139,9 @@ export function register(app) {
stream.pipe(res)
} catch (err) {
console.error('[nuggets-workflow] audio error:', err.message, err.cause?.message ?? '')
if (!res.headersSent) res.status(500).json({ message: 'Audio stream failed.' })
// Admin-only route, so the reason is safe to show and saves a trip to the server logs.
const reason = [err.message, err.cause?.message].filter(Boolean).join(': ')
if (!res.headersSent) res.status(500).json({ message: `Audio stream failed${reason ? ` (${reason})` : ''}.` })
}
})
}