You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Settling a thread doesn't settle its finished subagent threads #33578
I searched existing issues and did not find a duplicate.
I included enough detail to reproduce or investigate the problem.
Related: #29999 reported the same thing. #30026 closed it by changing worktree cleanup only, and says settlement state is unchanged. #19657 is about the auto-settle sweep picking up hidden subagent threads.
Area
apps/server
Steps to reproduce
In a thread, let the agent start subagents (Claude Agent, a Workflow, or delegate_task).
Let them finish, then settle the parent from the sidebar or with t3_thread_organize (action: "settle").
Call t3_thread_list with settled: false, allProjects: true.
Expected behavior
The parent's finished subagent threads are settled with it. They aren't shown in the sidebar, so the user can't settle them by hand.
Actual behavior
Only the parent is settled. settleThread in ThreadManagementService.ts dispatches one thread.settle for input.threadId and doesn't look at children, so each child keeps settledAt: null.
On my Mac (0.1.8-nightly.20261109.4429), orchestration_v2_projection_threads without deleted rows:
count
Top-level threads, unsettled
24 of 544
Subagent threads, unsettled
6,348 of 6,455
Unsettled subagent threads whose parent is settled
5,059
…with their own worktree
609
Unsettled subagent threads whose parent row is gone
86
t3_thread_list therefore reports about 6,400 unsettled threads. I have 24 open sessions. When I asked an agent to tidy up, it could only settle them one call at a time.
Suggested fix
When a thread settles, also settle its subagent descendants that have no active run or pending request, and reverse that on unsettle. Add a one-time pass that settles children of already-settled parents.
with t as (
select thread_id,
json_extract(payload_json, '$.lineage.parentThreadId') p,
json_extract(payload_json, '$.settledAt') s
from orchestration_v2_projection_threads where deleted_at is null)
selectcount(*) from t c join t par onpar.thread_id=c.pwherec.s is nullandpar.sis not null;
Yeah, seeing this too on Linux with 0.1.10-nightly.20261111.4529.
A read-only snapshot found 27,381 completed subagent chats still marked unsettled. Following the full parent chain, 24,002 belonged to settled top-level parents and another 3,110 to archived/deleted parents. Of the 24,002, 24,001 finished before their parent was settled. Most descendants were nested, so checking only the immediate parent substantially undercounted it.
This matches the parent-based settlement work in #19665, including the case where automatic settlement is disabled.
After manually settling the idle descendants through normal T3 commands, the unsettled PR-snapshot query dropped from 30,240 rows / 50.2 MB to 501 rows / 0.82 MB. This measures the metadata returned by that query.
(commented on behalf of Aritra Bandyopadhyay by GPT 6.1 Sol)
Fixed by #19665, now on main: Settling a parent now automatically settles its eligible idle local subagent descendants, including existing children of settled or missing parents and with automatic settlement disabled, so those children disappear from the unsettled thread list.
Activity
docs: archive is the sanctioned end state for retired T3 threads
Techie5879 commentedon Nov 11, 2026
Yeah, seeing this too on Linux with
0.1.10-nightly.20261111.4529.A read-only snapshot found 27,381 completed subagent chats still marked unsettled. Following the full parent chain, 24,002 belonged to settled top-level parents and another 3,110 to archived/deleted parents. Of the 24,002, 24,001 finished before their parent was settled. Most descendants were nested, so checking only the immediate parent substantially undercounted it.
This matches the parent-based settlement work in #19665, including the case where automatic settlement is disabled.
After manually settling the idle descendants through normal T3 commands, the unsettled PR-snapshot query dropped from 30,240 rows / 50.2 MB to 501 rows / 0.82 MB. This measures the metadata returned by that query.
(commented on behalf of Aritra Bandyopadhyay by GPT 6.1 Sol)
juliusmarminge commentedon Nov 11, 2026
Fixed by #19665, now on main: Settling a parent now automatically settles its eligible idle local subagent descendants, including existing children of settled or missing parents and with automatic settlement disabled, so those children disappear from the unsettled thread list.