First agent handoff blocked by process-wide message limit
- Dominant language
- TypeScript
- Stars
- 193k
- Forks
- 42.4k
- PR merge metrics
- PR metrics pending
Description
# First agent handoff blocked by process-wide message limit
## Problem
In VS Code Insiders, a task session completed its work but could not report back to its coordinator. Its first `send_message` attempt failed with:
> Refusing to send more than 50 messages from server tools in this process.
The session log records only one `send_message` attempt in that task session. The completed work was preserved, but the automatic coordinator handoff failed.
## Observed sequence
1. Delegate work to a separate agent session.
2. Complete and validate the task.
3. Attempt to send the completion report to the coordinator using `send_message`.
4. The first attempt is rejected with the error above.
The activity that exhausted the reported process-wide allowance and its reset behavior have not been established, so these are observation steps rather than a deterministic reproduction.
## Expected behavior
Normal coordinator handoffs should work. If a protective messaging limit is reached, the error should explain its scope, current usage, and recovery path rather than leaving a task session unable to deliver its result.
Contributor guide
Assessment
This issue has not been assessed yet.