claude-code - 💡(How to fix) Fix [BUG] Spawned team agents on macOS report "Spawned successfully" but never read mailbox; processes idle indefinitely [1 comments, 2 participants]

Official PRs (…)
ON THIS PAGE

Recommended Tools

×6

Utilities matched from this issue’s tags and category — try them while you read without losing context.

GitHub issue graph ai analysis

Paste a GitHub issue URL. We fetch that issue, discover linked issues from bodies/comments/timeline, collect linked pull requests, and produce a structured English report.

The report is written in English Markdown for sharing and archival.

Helpful · Quick feedback

Loading…
GitHub stats
anthropics/claude-code#53767Fetched 2026-04-28 06:47:47
View on GitHub
Comments
1
Participants
2
Timeline
5
Reactions
0
Author
Timeline (top)
labeled ×4commented ×1

Error Message

Error Messages/Logs

No error output. Failure is silent. Inbox file content (truncated):

RAW_BUFFERClick to expand / collapse

Preflight Checklist

  • I have searched existing issues and this hasn't been reported yet
  • This is a single bug report
  • I am using the latest version of Claude Code

What's Wrong?

After TeamCreate followed by Agent (with team_name, name, run_in_background: true), the parent reports "Spawned successfully" and the child agent process does start (visible in ps), but the agent never consumes its mailbox. Messages in ~/.claude/teams/<team>/inboxes/<name>.json stay read: false indefinitely. The team-lead never receives a reply.

Reproduced consistently across:

  • Both Opus 4.7 and Haiku 4.5
  • Both single-agent and two-agent spawns (proponent + opponent)
  • Fresh TeamCreate after manual cleanup of stale team/inbox dirs
  • Idle process lifetimes observed up to 12+ minutes with zero inbox reads

TeamDelete does not terminate child processes; shutdown_request messages also go unread (since the inbox poll never runs). Manual pkill -f 'agent-id.*<team>' is the only reliable cleanup.

What Should Happen?

A spawned background teammate should poll its inbox and either consume the initial prompt sent at spawn time or respond to subsequent SendMessage calls. The team-lead should receive responses (or at least see read: true on the inbox file).

Error Messages/Logs

No error output. Failure is silent. Inbox file content (truncated):

``` [ { "from": "team-lead", "text": "...prompt...", "timestamp": "2026-04-27T06:08:22.512Z", "read": false } ] ```

`ps` showed long-lived child processes such as: ``` /Users/<user>/.local/share/claude/versions/2.1.119 --agent-id proponent@love-dialectic --agent-name proponent --team-name love-dialectic --agent-color blue --parent-session-id <uuid> --agent-type general-purpose --model claude-opus-4-7 ```

Steps to Reproduce

  1. Enable agent teams (`CLAUDE_CODE_EXPERIMENTAL_AGENT_TEAMS=1`) and start Claude Code on macOS.
  2. From the parent session, call `TeamCreate` with a fresh team name.
  3. Call `Agent` with `team_name`, a `name`, `run_in_background: true`, and a short prompt instructing the agent to immediately `SendMessage` back to `team-lead`.
  4. Wait several minutes. Inspect `~/.claude/teams/<team>/inboxes/<name>.json`.
  5. Observe: `read: false`, no SendMessage to team-lead, child process still alive in `ps`.

This differs from #42391 (Linux tmux 255-byte split): on macOS the launch command runs and the child process does start; it just never polls its mailbox.

Claude Model

Opus

Is this a regression?

I don't know

Claude Code Version

2.1.119 (Claude Code)

Platform

Anthropic API

Operating System

macOS

Terminal/Shell

iTerm2

Additional Information

  • Darwin 24.6.0
  • A large number of MCP servers are loaded (chrome-devtools, playwright, jetbrains, claude-in-chrome, discord, context7, plus several skill plugins) — possibly relevant to bootstrap, but the symptom is consistent across attempts.
  • Related (different mechanism, same area:agents): #42391.

extent analysis

TL;DR

The issue can be mitigated by investigating the agent's inbox polling mechanism and ensuring it is properly configured to read messages from the inbox file.

Guidance

  • Verify that the agent's inbox polling interval is correctly set and that the agent is able to read from the inbox file ~/.claude/teams/<team>/inboxes/<name>.json.
  • Check the agent's configuration and code to ensure that it is properly handling the run_in_background: true flag and that the inbox polling mechanism is not being blocked or interrupted.
  • Investigate potential conflicts with other loaded MCP servers or plugins that may be interfering with the agent's ability to poll its inbox.
  • Consider adding logging or debugging statements to the agent's code to gain more insight into its behavior and why it may not be reading from the inbox file.

Example

No code snippet is provided as the issue does not contain sufficient information about the agent's code or configuration.

Notes

The issue may be related to the agent's configuration or the interaction with other loaded MCP servers or plugins. Further investigation is needed to determine the root cause of the issue.

Recommendation

Apply workaround: Investigate and adjust the agent's inbox polling mechanism and configuration to ensure it is properly reading from the inbox file. This may involve modifying the agent's code or configuration to handle the run_in_background: true flag correctly and to avoid conflicts with other loaded MCP servers or plugins.

Vote matrix · Quick signals

Works
Did the solution work? Tap to confirm.
Easy Fix
Was it a quick fix?
Time Saver
Did it save you time?
Blocking
Was it severely blocking?
Common Issue
Are others likely hitting this too?
Flaky / Intermittent
Is it intermittent?
Verified / Reproducible
Can you reproduce it reliably?
Loading…

Still need to ship something?

×6

Another batch ranked right after the header list — different links, same matching logic.

Back to top recommendations

TRENDING

claude-code - 💡(How to fix) Fix [BUG] Spawned team agents on macOS report "Spawned successfully" but never read mailbox; processes idle indefinitely [1 comments, 2 participants]