Repository navigation
Description
Before submitting
- I searched existing issues and did not find a duplicate.
- I included enough detail to reproduce or investigate the problem.
Area
apps/server
Steps to reproduce
- In a Claude thread, have the agent start a Claude Code Workflow (the Workflow tool runs in the background and returns a task ID such as
wg53xzo6q). - Before ending its turn, the agent follows the "Background work you wait on" instruction and calls
t3_background_waitwith the workflow's task ID.
Expected behavior
The agent should not need the call: a running workflow is a subagent item, and backgroundWorkHoldsCompletion already holds the thread in Working for subagents. If an agent does pass a workflow ID, the error should say that workflows already hold the thread, as it does for subagents, Agent tool and delegate_task IDs.
Actual behavior
The call fails with invalid_request (text below). Neither that message nor CLAUDE_BACKGROUND_WAIT_INSTRUCTIONS names Workflow, so the agent concluded that workflows "can't be registered" with the wait tool and told the user so as if it were a gap.
T3 behaved correctly throughout: the workflow's item (task:wg53xzo6q:subagent, type subagent, status running) kept run 1 running across the agent's turn end, pendingBackgroundTasks stayed empty, and the agent was woken when the workflow finished. Only the agent's explanation was wrong.
Impact
Cosmetic issue
Version or commit
0.1.12-nightly.20261125.5222 (source read at main c5d6aa1)
Environment
macOS 27.3 (arm64), T3 Code desktop nightly, Claude Code 2.1.331, Claude Opus 5.5 (claude-opus-5-5) on a claudeAgent-driver provider instance
Logs or stack traces
t3_background_wait {"taskIds":["wg53xzo6q"],"waiting":true}
-> invalid_request: None of these IDs is running background work on this thread, so this request registers no wait for them. If the task already finished, read its output now. Otherwise pass the task ID of a background command or Monitor you started. Subagent, Agent tool, and delegate_task IDs don't go here.Screenshots, recordings, or supporting files
No response
Workaround
None needed. Workflows already hold the thread.
A possible fix is one word in the unmatched message in ThreadManagementService.ts: "Subagent, Agent tool, Workflow, and delegate_task IDs don't go here; they keep the thread working on their own." I have not added an eval case, because the agent took no wrong action (it did not poll, sleep or schedule a wakeup), so there is no failing behavior for a case to reproduce. Related: #29772 and #29773, which fixed the harmful version of this for subagent IDs.
Investigated and written by Claude Opus 5.5 (claude-opus-5-5) in Claude Code, run from T3 Code.
Activity