Skip to content
Source
Sign inSign up
pingdotgg/t3code

fix(client-runtime): stop counting the workflow coordinator as a working agent #5808

Closedartieeg(GitHub profile, opens in a new tab)wants to merge 1 commit intomain fromrefs/pull/5808/headopened View on GitHub

Showing 3 changed files with 35 additions and 5 deletions.

x
0 of 3 viewed, 3 left
2 additions and 4 deletionsapps/web/src/components/AgentsPanel.tsxModified
View file
@@ -568,10 +568,8 @@
</ScrollArea>
<footer className="flex items-center justify-between border-t border-border/60 px-3 py-1.5 font-mono text-[.7rem] text-muted-foreground">
<span className="flex items-center gap-2">
- {model.runningCount + model.waitingCount > 0 ? (
- <span className="text-info-foreground">
- ● {model.runningCount + model.waitingCount} working
- </span>
+ {model.liveCount > 0 ? (
+ <span className="text-info-foreground">● {model.liveCount} working</span>
) : null}
{model.idleCount > 0 ? <span>{model.idleCount} idle</span> : null}
{model.settledCount > 0 ? <span>{model.settledCount} settled</span> : null}
22 additions and 0 deletionspackages/client-runtime/src/state/subagentRuntime.test.tsModified
View file
@@ -390,6 +390,28 @@
});
​
+ it("excludes the workflow coordinator from the live count", () => {
+ // The composer banner and the panel footer read liveCount. A workflow
+ // running one member must read "1 agent working", not 2 — the
+ // coordinator is the workflow itself, not a worker.
+ const model = deriveAgentPanelModel({ agents: roster });
+ // wf-1 (coordinator) + wf-1:wf:1 (member) are both live in the tally...
+ expect(model.runningCount).toBe(2);
+ // ...but only the member is an agent doing work.
+ expect(model.liveCount).toBe(1);