Show initial-agent workspaces as Working

This commit is contained in:
Mohamed Boudra
2026-06-04 17:49:13 +07:00
parent 88d44ab2c5
commit 1bca88bd30
10 changed files with 444 additions and 44 deletions
@@ -591,7 +591,10 @@ async function createAndMergeWorkspace(input: {
throw new Error(payload.error ?? "Failed to create worktree");
}
const normalizedWorkspace = normalizeWorkspaceDescriptor(payload.workspace);
input.mergeWorkspaces(input.serverId, [normalizedWorkspace]);
const workspaceForInitialMerge = input.createInput.firstAgentContext
? { ...normalizedWorkspace, status: "running" as const, statusEnteredAt: new Date() }
: normalizedWorkspace;
input.mergeWorkspaces(input.serverId, [workspaceForInitialMerge]);
return normalizedWorkspace;
}
@@ -726,6 +729,7 @@ function submitWorkspaceDraft(input: SubmitDraftInput): void {
useCreateFlowStore.getState().setPending({
serverId,
draftId,
workspaceId,
agentId: null,
clientMessageId,
text: text.trim(),