feat(chat): retry the last answer — redo-in-place Retry button on the latest brain bubble

This commit is contained in:
2026-08-29 18:32:15 -04:00
parent 1a60ecbd8b
commit 6832957ab0
7 changed files with 891 additions and 15 deletions
+6 -5
View File
@@ -99,11 +99,12 @@ def test_persisted_on_leave_flag_is_module_scoped_and_turn_reset() -> None:
"flag check first, set immediately before the persist call"
)
# Reset at the top of the turn handler (handleSend) — before the
# turn's fetch, where the other turn locals are initialized.
send = js.find("async function handleSend")
assert send != -1
top = js[send : send + 1500]
# Reset at the top of the turn handler (runTurn — phase 49 extracted
# the turn from handleSend) — before the turn's fetch, where the
# other turn locals are initialized.
turn = js.find("async function runTurn")
assert turn != -1
top = js[turn : turn + 1500]
assert "persistedOnLeave = false;" in top, (
"persistedOnLeave must be reset per turn, at the top of the turn handler"
)