Skip to content

Commit 650c9c7

Browse files
Preserve git action toast progress until HTTP completion
- Keep progress timestamps intact on `action_finished` and `action_failed` - Let the HTTP response path clear the active toast so the running description does not flash away
1 parent 529315b commit 650c9c7

1 file changed

Lines changed: 9 additions & 6 deletions

File tree

apps/web/src/components/GitActionsControl.tsx

Lines changed: 9 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -347,13 +347,16 @@ export default function GitActionsControl({ gitCwd, activeThreadId }: GitActions
347347
progress.lastOutputLine = null;
348348
break;
349349
case "action_finished":
350-
progress.phaseStartedAtMs = null;
351-
progress.hookStartedAtMs = null;
352-
break;
350+
// Don't clear timestamps here — the HTTP response handler (line 496)
351+
// sets activeGitActionProgressRef to null and shows the success toast.
352+
// Clearing timestamps early causes the "Running for Xs" description
353+
// to disappear before the success state renders, leaving a bare
354+
// "Pushing..." toast in the gap between the WS event and HTTP response.
355+
return;
353356
case "action_failed":
354-
progress.phaseStartedAtMs = null;
355-
progress.hookStartedAtMs = null;
356-
break;
357+
// Same reasoning as action_finished — let the HTTP error handler
358+
// manage the final toast state to avoid a flash of bare title.
359+
return;
357360
}
358361

359362
updateActiveProgressToast();

0 commit comments

Comments
 (0)