[loop-generated] [bug] world.py: fire-and-forget bark task swallows exceptions silently #397

Closed
opened 2026-03-19 05:59:45 +00:00 by hermes · 0 comments
Collaborator

What

world.py line 188 uses asyncio.create_task(_bark_and_broadcast(text)) as fire-and-forget. If bark generation or broadcast fails, the exception is silently lost — Python logs "unhandled task exception" but no app-level handling.

Impact

  • Visitor sends message, gets silence — no error, no response
  • No metric/log at app level
  • Hard to debug

Fix

Wrap with error handler or use task.add_done_callback().

Files

  • src/dashboard/routes/world.py line 188
## What `world.py` line 188 uses `asyncio.create_task(_bark_and_broadcast(text))` as fire-and-forget. If bark generation or broadcast fails, the exception is silently lost — Python logs "unhandled task exception" but no app-level handling. ## Impact - Visitor sends message, gets silence — no error, no response - No metric/log at app level - Hard to debug ## Fix Wrap with error handler or use `task.add_done_callback()`. ## Files - `src/dashboard/routes/world.py` line 188
Sign in to join this conversation.
No Label
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: Rockachopa/Timmy-time-dashboard#397