fix(session): prevent consumed follow-ups from replaying after restart (#6299)

* fix(session): atomically acknowledge consumed follow-ups

* refactor(webui): drop legacy follow-up replay compatibility
This commit is contained in:
chengyongru authored and GitHub committed 2026-10-19 11:31:19 +08:00
1 parent 743d40bbba
commit 53e0edf709
17 files changed
+645 -215

No files matched your search

+14
View File
@@ -50,3 +50,17 @@ it("lets users type into prompt search immediately after opening it", async () =
expect(onJumpToPrompt).toHaveBeenCalledWith("two");
await waitFor(() => expect(screen.queryByRole("dialog")).not.toBeInTheDocument());
});
it("keeps an unknown recovered time blank while the prompt remains navigable", async () => {
const user = userEvent.setup();
const onJumpToPrompt = vi.fn();
render(<PromptNavigator messages={[
{ id: "undated", role: "user", content: "Undated recovered input", createdAt: 0 },
]} onJumpToPrompt={onJumpToPrompt} />);
await user.click(screen.getByRole("button", { name: "Message navigation" }));
const prompt = screen.getByRole("button", { name: "Jump to message: Undated recovered input" });
expect(prompt.textContent).toBe("Undated recovered input");
await user.click(prompt);
expect(onJumpToPrompt).toHaveBeenCalledWith("undated");
});