TeamDelete returns success but teammate tmux pane survives

Resolved 💬 3 comments Opened May 7, 2026 by nazt Closed May 11, 2026

Summary

TeamDelete returns { success: true } while a teammate's tmux pane is still alive. The lead's status bar continues showing Idle · teammates running after deletion. The teammate acknowledged shutdown_request but its pane was never terminated.

Reproduction

  1. TeamCreate("learn-mawjs")
  2. Spawn 5 teammates via Agent tool with team_name set (tmux backend, Haiku model, subagent_type: "general-purpose")
  3. Wait for all 5 to complete their tasks + send reports
  4. SendMessage shutdown_request to each teammate
  5. 4 of 5 respond with shutdown_approved and their panes terminate
  6. 1 teammate (fed-protocol) shows:
  • "Shutdown request from team-lead" rendered in pane
  • Two Invalid tool parameters errors (red) — likely its shutdown_response reply failing validation
  • Then: "Approving shutdown — TASK 2 complete. … Team lead has been notified."
  • Pane stays alive. Cursor active.
  1. TeamDelete() → returns { success: true, message: "Cleaned up directories and worktrees..." }
  2. Lead's footer still shows: @main @fed-protocol · shift+↓ to expand
  3. tmux list-panes confirms the pane exists

Expected

Either:

  • TeamDelete should fail if a teammate pane is still alive (the docs say "TeamDelete will fail if the team still has active members"), OR
  • TeamDelete should kill surviving panes as part of cleanup

And: if the teammate's shutdown_response fails tool validation, the system should still terminate the pane (the intent was clearly to shut down).

Possible cause

The shutdown_response from the teammate may have included invalid parameters (the Invalid tool parameters errors in the pane suggest this). If the response validation rejects the reply, the shutdown handshake never completes — but TeamDelete doesn't check for this and reports success anyway.

Environment

  • Claude Code v26.4.18
  • Opus 4.7 (1M context) as lead
  • Haiku 4.5 as teammates
  • tmux backend (teammateMode: "tmux")
  • macOS Darwin 25.4.0

Screenshots

_(Nat has screenshots showing the split-pane state; can attach if needed)_

Workaround

Manual tmux kill-pane on the orphaned pane, or bash ~/.claude/skills/team-agents/scripts/cleanup.sh.

View original on GitHub ↗

This issue has 3 comments on GitHub. Read the full discussion on GitHub ↗