[BUG] Subagent dispatch prompt and returned result hidden in main thread — collapsed line cannot be expanded (regression after 2.1.160, still in 2.1.170)

Open 💬 0 comments Opened Jun 9, 2026 by marianobrolio-santex

Environment

  • Claude Code version: 2.1.170 (native install, Linux)
  • Platform: Linux (WSL2, Windows Terminal, TERM=xterm-256color)
  • Model: claude-fable-5 (also reproduced on Opus 4.x sessions)
  • Regression range: worked correctly in 2.1.160; broken somewhere in 2.1.161–2.1.170 (I skipped intermediate versions, but I downgraded to 2.1.160 specifically because of this, and just confirmed it still reproduces on 2.1.170)

Description

When the main thread dispatches a subagent via the Agent/Task tool, the main-thread UI shows only a collapsed one-line summary (e.g. Done (10 tool uses · 45.6k tokens · 2m 2s)). Neither the dispatch prompt (the brief the main agent wrote for the subagent) nor the subagent's final returned text can be viewed from the UI:

  • The collapsed line cannot be expanded (ctrl+e / ctrl+o do not reveal the prompt or the result)
  • The data is not lost — both are fully present in the session transcript JSONL — it is purely a rendering/visibility issue

This breaks any plan-review workflow built on subagents. Example from a real session today: an architecture-design subagent returned a 15,587-character implementation plan as its final result. The orchestrator then asked me to choose between the proposed options — but the plan itself was never displayed, so there was nothing to base the decision on without manually parsing the transcript JSONL.

Steps to reproduce

  1. In an interactive session, have the main agent dispatch a subagent with a substantial prompt, e.g. a custom agent that produces a design/plan as its final message (any Task/Agent tool call reproduces it; mine came from a plugin command that spawns architect/reviewer agents)
  2. Wait for the subagent to finish
  3. Observe the main thread

Expected behavior

As in ≤ 2.1.160: the subagent dispatch shows the prompt/brief being sent, and on completion the agent's returned result is rendered (or at minimum is expandable / visible in the ctrl+o transcript view).

Actual behavior

Only the collapsed summary line is shown. No way to read the brief or the result from the UI.

Evidence (session transcript JSONL, v2.1.170)

The tool_use and tool_result entries contain the full content that the UI never renders:

tool_use   Agent  subagent_type=<custom architect agent>
           input.prompt length = 5,022 chars     <- brief, not displayed

tool_result (same tool_use_id)
           text block #1 length = 15,587 chars   <- full returned plan, not displayed
           text block #2: "agentId: ... <usage>subagent_tokens: 45625, tool_uses: 10,
           duration_ms: 122378</usage>"          <- only this summary is reflected in the UI

Happy to provide the full (redacted) JSONL excerpts or run a bisect across 2.1.161–2.1.169 if that helps narrow the regression.

View original on GitHub ↗