Skip to content

Commit 70de69f

Browse files
shivamhwpclaude
andcommitted
fix(web): window title keeps Working while a turn waits on a child thread
A turn blocked on a delegated thread is still running, but the title dropped its status, which reads as a finished turn. Co-Authored-By: Claude Opus 5.5 <[email protected]>
1 parent 7bf689d commit 70de69f

2 files changed

Lines changed: 5 additions & 1 deletion

File tree

‎apps/web/src/components/Sidebar.logic.test.ts‎

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -319,7 +319,8 @@ describe("resolveSidebarThreadStatus", () => {
319319
[{ ...idle, runtime: { ...runtime, status: "preparing" as const } }, "Working"],
320320
[{ ...idle, runtime }, "Working"],
321321
[{ ...idle, runtime, pendingGuestMessageCount: 1 }, "Working"],
322-
[{ ...idle, runtime, blockedOnThreadWait: true }, null],
322+
[{ ...idle, runtime, blockedOnThreadWait: true }, "Working"],
323+
[{ ...idle, runtime: { ...runtime, status: "idle" as const } }, null],
323324
[{ ...idle, runtime: { ...runtime, status: "failed" as const } }, null],
324325
[{ ...idle, runtime: { ...runtime, status: "completed" as const } }, null],
325326
[idle, null],

‎apps/web/src/components/Sidebar.logic.ts‎

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -995,6 +995,9 @@ export function resolveWindowTitleThreadStatus(thread: SidebarThreadStatusInput)
995995
case "preparing":
996996
case "working":
997997
return THREAD_STATUS_TEXT.working;
998+
case "waiting":
999+
// Waiting on a child thread is still this turn, so it must not read as finished.
1000+
return thread.runtime?.status === "running" ? THREAD_STATUS_TEXT.working : null;
9981001
default:
9991002
return null;
10001003
}

0 commit comments

Comments
 (0)