Agent teams: tmux-backed agents never receive initial prompt or messages (v2.1.32)
Bug Description
Agent teams using the tmux backend spawn correctly but agents never receive their initial prompt or any subsequent messages. The mailbox-based message delivery is completely broken for tmux-backed agents.
Steps to Reproduce
- Start Claude Code inside a tmux session
- Create a team with
spawnTeam - Create tasks and spawn teammates (agents)
- Agents launch in new tmux panes with correct
--agent-*CLI flags - Agents boot to the idle welcome screen ("Try 'how do I log an error?'") and never receive instructions
Expected Behavior
Agents should receive their initial prompt via mailbox and begin working on assigned tasks.
Actual Behavior
- Claude Code launches in new tmux panes successfully
- The
backendTypeis correctly set to"tmux"in team config - Agents sit at the idle welcome prompt indefinitely
- Tasks remain in
[pending]status forever SendMessage(including shutdown requests) reports success but messages are never delivered- Agents are completely unreachable via the messaging system
Workaround
Running Claude Code outside of tmux (plain terminal) forces the in-process backend, which works correctly. All team features (task creation, message delivery, shutdown, cleanup) work fine with in-process agents.
Comparison
| Aspect | In-Process Backend | Tmux Backend |
|--------|-------------------|--------------|
| Agent launch | ✅ Works | ✅ Works |
| Prompt delivery | ✅ Works | ❌ Broken |
| Task execution | ✅ Works | ❌ Never starts |
| Message delivery | ✅ Works | ❌ Broken |
| Shutdown delivery | ✅ Works | ❌ Broken |
Environment
- Claude Code v2.1.32
- Linux (Arch Linux / kernel 6.18.3-arch1-1)
- tmux 3.5a (confirmed working tmux session)
Additional Context
The tmux panes show the full launch command with all agent flags:
cd /path/to/project && CLAUDECODE=1 /home/user/.local/share/claude/versions/2.1.32 --agent-id branch-checker@tmux-test --agent-name branch-checker --team-name tmux-test --agent-color green --parent-session-id <session-id> --agent-type general-purpose --model haiku
The process starts and renders the Claude Code UI, but the mailbox/IPC connection that should deliver the initial prompt and subsequent messages never connects. This appears to be a regression in how the tmux backend initializes mailbox polling for spawned agents.
This issue has 4 comments on GitHub. Read the full discussion on GitHub ↗