Agent subagent results never delivered to parent in background job sessions

Open 💬 1 comment Opened Jul 6, 2026 by KathrynN

Bug

When running Claude Code as a background job (spawned via the daemon), agents spawned with the Agent tool never deliver their completion results back to the parent session. The parent blocks indefinitely on run_in_background: false, or never receives a completion notification for background agents.

Reproduction

  1. Start Claude Code as a background job (via the daemon or desktop app)
  2. Enter a worktree (EnterWorktree)
  3. Spawn any agent — even a trivial one:

``
Agent({ prompt: "Say hello and nothing else.", run_in_background: false })
``

  1. The agent spawns, runs, completes (visible in the tmux swarm view), and goes idle
  2. The parent session never receives the result — it blocks forever

Observed behavior

  • The agent process starts and appears in ps aux and the tmux swarm view
  • The agent completes its work (verified by viewing its tmux pane)
  • An idle_notification teammate message is delivered to the parent, but the Agent tool's completion callback never fires
  • run_in_background: false blocks indefinitely
  • run_in_background: true (default) never sends a completion notification

Expected behavior

The Agent tool should return the agent's final text output to the parent session when the agent completes.

Environment

  • Claude Code v2.1.202
  • macOS (Darwin 25.5.0, arm64)
  • Running as a background job via the daemon
  • Inside a git worktree (.claude/worktrees/)
  • Tested with logic-reviewer, security-reviewer, test-reviewer, nitpick-reviewer, general-purpose, and default agent types — all exhibit the same behavior
  • Tested across two separate attempts (8+ agents total including a trivial "say hello" agent) in the same session

Impact

This blocks any multi-agent workflow from a background job session. Skill workflows that spawn reviewer subagents become non-functional — agents complete but results are lost.

Workaround

None found. The only option is to not use subagents from background job sessions.

View original on GitHub ↗

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