P0: long agent turns block queued user messages; pending messages lost on disconnect

Open 💬 1 comment Opened Jul 2, 2026 by lonestarsoftware

What happened

During a long-running agent turn (many chained tool calls, or background operations), user messages typed in the interim are held as pending and are not read/processed until the turn completes. When a turn runs for minutes, the user effectively cannot interrupt or be heard.

Worse: if the client/app is closed or disconnects while messages are still pending, those queued messages are lost — never delivered to the agent and not persisted for the next session.

Impact (why P0)

  • The user cannot steer or interrupt a busy agent; instructions are silently dropped.
  • Long-running agent sessions (workflows, multi-step tasks) become unresponsive and, in practice, unusable.
  • Real, repeated cost: users re-type the same corrections and watch them get ignored because the agent is mid-turn and their messages never land.

Repro

  1. Start a task that triggers a long agent turn (long tool chains / a background workflow / repeated large operations).
  2. Type messages during that turn.
  3. Observe they stay pending and are not acted on until the turn ends.
  4. Close/disconnect the app while messages are pending → those messages are gone.

Expected

  • Queued user messages should reach the agent promptly / at safe interruption points, not only after a long turn finishes.
  • Queued user messages should be durably persisted so they survive a disconnect and are delivered when the session resumes.
  • Ideally, a user message can reliably interrupt or queue ahead of ongoing work.

Environment

Claude Code, VS Code extension (Windows). Surfaced during a long agent session with background workflows.

View original on GitHub ↗

This issue has 1 comment on GitHub. Read the full discussion on GitHub ↗