Skip to content

fix: name the running reply's own project after a reload - #31229

Merged
KiroCrewCaptain merged 1 commit into
mainfrom
fix/issue-20352
Nov 17, 2026
Merged

KiroCrewCaptain merged 1 commit into
mainfrom
fix/issue-20352

Conversation

@JLargent42

@JLargent42 JLargent42 commented Nov 6, 2026 •

Copy link
Copy Markdown
Contributor

Builds on #31080, which has merged; this diff is the single fix commit on top of main.

Problem / Motivation

Goal: After a reload or reconnect mid-reply, the composer's project chip tooltip names the project the running reply actually works in, not a project picked while it ran.

Start a reply in project A, pick project B while it runs, then reload the page. The chip's tooltip says the current reply finishes in B. The reply's kiro-cli process is still in A. ChatInput takes its start-of-response snapshot from the slot's live project, which already follows the pick, so any remount during the reply reads the pick.

Why it matters

The mid-reply note exists so a user who switches projects knows which directory the running reply's file links and edits belong to. After a reload, reconnect or a move between running chats, it states the wrong directory, which is the exact confusion the note is meant to prevent.

Not a goal

What changed (motivation → approach → change)

Symptom: a remount takes the start-of-response snapshot from project, which a mid-reply pick has already moved. Root cause: the browser has no authoritative reading of the running turn's directory; only the server knows it.

Change: turn admission (src/kiro_crew/dashboard/chat_turn/turn_admission.py) pins (turn_generation, project) on the slot when the turn claims its session, and re-pins the reused process's cwd when a reset is deferred (sub-agents attached). The pin is a new _ChatSlot field (src/kiro_crew/dashboard/state_parts/chat_slot.py, initialised in slot_turns.py). src/kiro_crew/dashboard/slot_projection.py publishes it as turn_project, null unless a turn is running in the generation the pin was taken in, so a pin from an earlier turn never names the current one. On the frontend, ChatSlot.turn_project (website/src/types/index.chat.ts) is passed by website/src/pages/chat/page/ComposerDockView.tsx as the new turnProject prop (website/src/components/chat-input/props.ts), and website/src/components/ChatInput.tsx passes it into #31080's useStagedProject (website/src/components/chat-input/stagedProject.tsx), which prefers it over its local snapshot, keeping the snapshot only while the server has no reading (older gateway, or a turn not yet claimed). Both the mid-reply note and the pending badge therefore follow the server's reading, so after a reload onto a staged pick the chip still shows the pick as pending. The new slot field is listed in the facade, running-readers and spec tables.

Backwards compatibility

Compatible: turn_project and turn_project_fallback are new optional summary fields; an older gateway omits both and the composer falls back to its existing snapshot.

Removes nothing: the diff only adds a slot field, two summary keys and two optional props (turnProject, turnProjectFallback).

Tests

  • test/test_chat_runner_mid_turn_project.py::test_summary_names_the_turn_project_after_a_mid_reply_pick: after a mid-reply pick the summary's turn_project stays the claimed directory while project follows the pick.
  • test/test_chat_runner_mid_turn_project.py::test_turn_project_pin_from_another_generation_names_no_turn: a pin from an earlier turn generation reads as null.
  • test/test_chat_slot_facade_contract.py, test/test_state_parts_facade.py, test/test_slot_running_readers.py: the new slot field and summary key are registered in the facade contracts and the running-readers table.
  • website/src/test/ChatInput.turnProject.test.tsx: remount onto a mid-reply pick names the turn project and still shows the pending badge; a turn_project arriving after mount (reconnect) is taken; a fresh turn in B reports B with no pending badge; moving between running chats names each chat's own turn project; the snapshot stays while the server has no reading.

Proof: run on head a8c1794: test/test_chat_runner_mid_turn_project.py (including test_summary_names_the_turn_project_after_a_mid_reply_pick, test_summary_names_the_fallback_directory_after_a_hidden_scratch_project and test_deferred_reset_turn_describes_the_reused_process_directory, which now also pins turn_project_fallback false: changing bool(_fallback) to True fails it), test/test_chat_slot_facade_contract.py, test/test_slot_running_readers.py, test/test_state_parts_facade.py and test/test_turn_golden.py (40 passed), plus ChatInput.turnProject and ChatInput.stagedProject vitest (19 passed).

Local gate: black, subprocess-encoding, isort, flake8, mypy, comment-history, brand-name and file-line-cap pass; npm run build passes; tsc --noEmit passes; the frontend related set (572 files, 15,079 tests) passes on the rebased head. Backend related set: 59,765 passed. The backend reds are outside this diff and fail the same way at the merge-base on this host, so they were deselected: src/kiro_crew/apps/builtins/file_explorer/tests/test_server.py, test/test_design_tweak_backend.py and test/test_design_tweak_devproc.py (403 on the /local/home path ancestry); test/test_crew_image_build_plan.py and test/test_mcp_slim_entry.py (libffi in subprocesses); test/test_dashboard_gallery_approvals.py (PlatformCompositionError in this sandbox); test/test_docker_entrypoint.py (libffi, two tests); test/test_living_ui_harness.py::test_the_dashboard_mode_reruns_under_the_runtime_python; test/test_find_ui_auto.py (the "Continue with GitHub" auto-tier path); test/test_kas_bundle.py::TestSpawnRoute (two tests), test/test_native_skill_projection.py::test_launch_record_resources_match_the_alias_file_kiro_cli_loads and test/test_auto_improvement_members.py::test_assignments_build_real_context_from_only_their_private_store.

Hidden-scratch fallback: when the chat stores a hidden scratch folder, the turn runs in the default folder, so turn_project differs from project with no pick made. The pin keeps the stored scratch folder the turn fell back from, and the summary publishes turn_project_fallback only while project still names it. useStagedProject then keeps the stored project as its pending baseline, so no false "Starts next message" badge appears. A pick made over the scratch folder moves project, the flag drops, and the pick is pending, also after a reload (vitest case shows the pick as pending after a reload that follows a pick over a scratch fallback, and the projection unit test). The split-pane ChatPane composer now gets both fields too. Tests: test_summary_names_the_fallback_directory_after_a_hidden_scratch_project and the shows no pending pick when the turn fell back from a hidden scratch folder vitest case.

Manual verification

N/A — unit coverage sufficient: the backend tests drive a real turn admission with a mid-reply pick, and the frontend tests remount the composer with the slot summary a reload produces. Not reproduced against a live reload.

Screenshots / video

The real ChatInput project chip with a reply running, rendered from a local capture page (website/capture/project-chip-mid-turn.tsx) with every /api call stubbed, so no gateway was involved. One script starts vite in-process and drives it (website/scripts/capture-project-chip-pending.mjs). The page prints the chip's accessible name under the composer, because a native tooltip does not paint.

Reload onto a staged pick (?reload=1): the chat's project is already the pick (OtherRepo), as after a reload mid-reply, and the server reports the running reply's project (KiroCrew). Before is current main (no server reading: the chip names the pick as the reply's project and shows no badge), after is this head.

main (before) this head (after)
full, dark reload main dark reload head dark
compact, dark reload compact main dark reload compact head dark
full, light reload main light reload head light
compact, light reload compact main light reload compact head light

Hidden-scratch fallback (?fallback=1): the chat stores a scratch folder, the reply runs in KiroCrew, nobody picked anything. After: no badge, "This reply finishes in KiroCrew."

fallback head dark
fallback head light

Mid-reply pick in the same session (unchanged by this PR, from #31080), dark:

before pick, dark
pending, dark
pending compact, dark
pending locked by sub-agents, dark

Related Issues

Closes #20352

Follow-up to #17729, part of #7263.

Sibling sweep

Swept: git grep -nE "turnStartProject|turn_project|useStagedProject" -- src/ website/src/
Siblings: useStagedProject has two client readers, the main composer (ComposerDockView) and the split-pane composer (ChatPane); both now receive turn_project and turn_project_fallback. The server-side _turn_project readers already use the turn's own directory.

Pattern harvest

Not generalizable: a client-side snapshot of server state that a remount retakes from already-moved state is specific to this staged-pick flow.

Checklist

  • At most two commits (one is the norm), with a Conventional Commits title (feat|fix|docs|style|refactor|perf|test|chore|ci|build|revert: ...)
  • Existing tests pass and new tests added for new functionality
  • Self-review completed; code follows project style guidelines
  • Documentation updated (if applicable)
  • No secrets, credentials, or internal references in the diff

@JLargent42
JLargent42 requested review from a team and KiroCrewCaptain as code owners November 6, 2026 07:49
@JLargent42
JLargent42 requested a review from Zedmor November 6, 2026 07:49
@github-actions github-actions Bot added the readiness: checking Automated validation is still running label Nov 6, 2026
@github-actions

github-actions Bot commented Nov 6, 2026 •

Copy link
Copy Markdown
Contributor

Design Review (Opus 5.5) — ✅ PASS

Design-level review of cd7fa62ba96f9ad6d7528da78a050a9e15a860f3 — updated in place on each push. A BLOCK verdict blocks PR readiness; PASS does not.

Design-Verdict: PASS

Nothing blocks: the server already knows which directory the running turn is in, so having it publish that reading fixes the cause, the new fields are additive, and older gateways still get the old snapshot.

[DESIGN-REVIEWED] cd7fa62

Description read

[DESCRIPTION-READ] 25f9426e30731f15e9e18b523c6a7a16cbf80afcc0bdfe86f584f811e32d1ea9

That sha256 names everything this verdict read: the PR description, plus the 1 evidence file(s) the workflow collected from it and handed this review. It covers that evidence because the media strip replaces every attachment URL with the same placeholder, so an edit swapping one attachment for another would leave the description's captured text identical while what this review judged changed. Recompute it with .github/scripts/pr-description-capture.sh over the same inputs; if it differs, the description or that evidence changed after this verdict was formed and any finding drawn from either is unproven.

@github-actions github-actions Bot added readiness: action required A blocking check or review needs attention and removed readiness: checking Automated validation is still running labels Nov 6, 2026
@github-actions github-actions Bot added readiness: checking Automated validation is still running and removed readiness: action required A blocking check or review needs attention labels Nov 6, 2026
@github-actions

github-actions Bot commented Nov 6, 2026 •

Copy link
Copy Markdown
Contributor

UX Review (Opus 5.5) — ✅ PASS

UX-level review of cd7fa62ba96f9ad6d7528da78a050a9e15a860f3 — updated in place on each push. A BLOCK verdict blocks PR readiness; PASS does not.

UX-Verdict: PASS

Nothing blocks: the diff adds no control or string, only feeds the server's project into the existing tooltip and badge. The blind reader read the reload state (shot-02) correctly and was sure of it.

Notes

  • Hidden-scratch fallback (shot-09/10): the chip says "old-session" but the tooltip says "This reply finishes in KiroCrew", with no badge. The reader said "the label says one folder and the sentence names another -> confusing". When turnProjectFallback is set, add a tooltip line saying the reply runs in the default folder because the stored folder is unavailable.

[UX-REVIEWED] cd7fa62

Description read

[DESCRIPTION-READ] db1db5d6e5e00e6f4f3efdf627002075c342349c229a5d03f4daab24ebc90edb

That sha256 names everything this verdict read: the PR description, plus the 17 evidence file(s) the workflow collected from it and handed this review. It covers that evidence because the media strip replaces every attachment URL with the same placeholder, so an edit swapping one attachment for another would leave the description's captured text identical while what this review judged changed. Recompute it with .github/scripts/pr-description-capture.sh over the same inputs; if it differs, the description or that evidence changed after this verdict was formed and any finding drawn from either is unproven.

@github-actions

github-actions Bot commented Nov 6, 2026 •

Copy link
Copy Markdown
Contributor

First Principles Review (Opus 5.5) — ✅ PASS

Premise-level review of cd7fa62ba96f9ad6d7528da78a050a9e15a860f3 — why this exists and whether the shipped surface is the smallest honest version. Updated in place on each push. A BLOCK verdict blocks PR readiness; PASS does not.

First-Principles-Verdict: PASS

Nothing blocks. The fix is aimed at the cause the description names: until now only the server knew the running turn's directory. Every new field has at least one real consumer.

Notes

  • Item 3 — inherited: the fallback flag only exists to stop item 1 from showing a false pending badge on a hidden-scratch chat, so it is self-inflicted surface rather than a reported defect. It is still needed while turn_project can differ from project with no pick made. No smaller form is visible.

What this change ships

Inventory (6 items) — 5 justified

Intent: after a reload or reconnect mid-reply, the project chip's tooltip names the directory the running reply actually works in. This is a FIX (#20352).

  1. Slot summary now carries turn_project, the running turn's own directory, pinned to the turn generation — justified
  2. Composer tooltip and pending badge prefer the server's reading over the local snapshot after a remount — justified
  3. Slot summary carries turn_project_fallback, so a hidden-scratch fallback is not shown as a pending pick — inherited (see Notes)
  4. Split-pane ChatPane composer gets the same two fields (2 consumers counted: ComposerDockView.tsx, ChatPane.tsx) — justified
  5. Capture page and script gain ?reload=1 / ?fallback=1 scenes — rides along
  6. Spec paragraph for mid-reply project switch updated — justified

[FIRST-PRINCIPLES-REVIEWED] cd7fa62

Description read

[DESCRIPTION-READ] f7659417b0d2625b331d92967c4c5b70f5d552f4137752162fbe40e4988107d4

That sha256 names the PR description this verdict read. Recompute it with .github/scripts/pr-description-capture.sh; if it differs, the description changed after this verdict was formed and any finding drawn from the description is unproven.

@github-actions

github-actions Bot commented Nov 6, 2026 •

Copy link
Copy Markdown
Contributor

Opus 5.5 Review — ✅ no blocking findings

Reviewed cd7fa62ba96f9ad6d7528da78a050a9e15a860f3 — this comment is updated in place on each push.

Review details

No findings.

[OPUS-REVIEWED] cd7fa62

Verdict parsed from the review's SHA-scoped output markers for commit cd7fa62ba96f9ad6d7528da78a050a9e15a860f3.

False positive or not applicable? A repository writer can comment:
/ai-review override fable cd7fa62ba96f9ad6d7528da78a050a9e15a860f3 false-positive: <reason, 20 to 500 characters>

@github-actions

github-actions Bot commented Nov 6, 2026 •

Copy link
Copy Markdown
Contributor

GPT 6.1 Review — ✅ no blocking findings

GPT 6.1 completed its review of cd7fa62ba96f9ad6d7528da78a050a9e15a860f3 and found no blocking issues.

This comment is updated in place on each push.

Review details

No findings.
[GPT-REVIEWED] cd7fa62

False positive or not applicable? A repository writer can comment:
/ai-review override gpt cd7fa62ba96f9ad6d7528da78a050a9e15a860f3 false-positive: <reason, 20 to 500 characters>

@github-actions github-actions Bot added readiness: action required A blocking check or review needs attention and removed readiness: checking Automated validation is still running labels Nov 6, 2026
@JLargent42

Copy link
Copy Markdown
Contributor Author

CI fix: test/test_turn_golden.py failed because this PR adds the turn_project field to the slot summary (intended: the running turn's own directory, null when no dashboard turn has claimed a session). Regenerated the three goldens with python3 scripts/update_turn_golden_snapshots.py (each gains "turn_project": null), folded into the top commit 0f75aff.

@github-actions github-actions Bot added readiness: checking Automated validation is still running and removed readiness: action required A blocking check or review needs attention labels Nov 6, 2026
@github-actions github-actions Bot added readiness: action required A blocking check or review needs attention merge conflict Branch has merge conflicts with its base — author must resolve before merge and removed readiness: checking Automated validation is still running labels Nov 6, 2026
@github-actions github-actions Bot added readiness: checking Automated validation is still running and removed readiness: action required A blocking check or review needs attention merge conflict Branch has merge conflicts with its base — author must resolve before merge readiness: checking Automated validation is still running labels Nov 12, 2026
@github-actions github-actions Bot added readiness: passed Eligible automated validation passed for the current revision and removed merge conflict Branch has merge conflicts with its base — author must resolve before merge readiness: checking Automated validation is still running labels Nov 14, 2026

@KiroCrewCaptain KiroCrewCaptain left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for the rebase. On head 63c6281, one item from the earlier review still blocks merge.

Earlier review:

  • Stacked commit ahead of #31080: fixed. #31080 merged, and this head is now one commit on top of main.
  • Visual evidence: still open. See item 1.
  1. The attached frames do not show the reload path this PR changes (website/capture/project-chip-mid-turn.tsx:53). All 8 frames come from this capture page, and this PR does not change it. Its <ChatInput> passes isRunning, projectLocked and project, but never turnProject or turnProjectFallback. It also models the pick as a click in the same session, not as a remount. With turnProject undefined, the new branch in useStagedProject never runs, so the frames show what main already renders. The UX review on this head also says it cannot evaluate. It names three gaps: the tooltip after a reload onto a staged pick, the pending badge after a reload (full and compact), and no false badge after a hidden-scratch fallback. Fix: add a ?reload=1 mode that mounts ChatInput with project set to OtherRepo and turnProject set to KiroCrew. Add a ?fallback=1 mode with a scratch project, a turnProject, and turnProjectFallback set. The page already prints the chip's accessible name, so the tooltip text appears in the frame even though a native tooltip does not. Attach frames of the reload case before (main) and after (this head), full and compact, plus the fallback frame. Then re-run the UX review on the current body.

Optional:

  • The fallback flag on the deferred-reset re-pin (src/kiro_crew/dashboard/chat_turn/turn_admission.py:1175) has no test. Changing bool(_fallback) to True keeps every test green. Asserting that turn_project_fallback is false in test_deferred_reset_turn_describes_the_reused_process_directory would pin it.
  • The Proof line still names head 7f0961c and lists registry tests. If you re-run it on this head and include test_summary_names_the_turn_project_after_a_mid_reply_pick, it will show the tests that fail without the fix.
  • The Backwards compatibility line says one summary key and one prop, but the diff adds two of each (turn_project, turn_project_fallback, turnProject, turnProjectFallback). The fallback paragraph could also say that a real pick shows no pending badge after a reload.

@github-actions github-actions Bot added readiness: action required A blocking check or review needs attention and removed readiness: passed Eligible automated validation passed for the current revision labels Nov 14, 2026
@github-actions github-actions Bot added readiness: checking Automated validation is still running and removed readiness: action required A blocking check or review needs attention labels Nov 16, 2026
@JLargent42

Copy link
Copy Markdown
Contributor Author

Follow-up on the 11-14 22:15Z review, now on head c8b1de1 (still one commit, same base).

Blocking: the frames did not show the reload path. Fixed.

  • website/capture/project-chip-mid-turn.tsx has two new modes. ?reload=1 mounts ChatInput with project = OtherRepo and turnProject = KiroCrew, as after a reload mid-reply. ?fallback=1 mounts a scratch project with a turnProject and turnProjectFallback.
  • website/scripts/capture-project-chip-pending.mjs captures them (one script; it was started through vite's in-process JS API, no server from the shell, no dashboard token). With CAPTURE_EXPECT=main it asserts what main renders. The frames print the chip's accessible name under the composer.
  • The description now has before (a clean worktree of current origin/main) and after (this head), full and compact, dark and light, for the reload case, plus the fallback frames. On main the reload chip names OtherRepo as the reply's project with no badge; on this head it shows the badge and "This reply finishes in KiroCrew." The fallback frame shows no badge and "This reply finishes in KiroCrew."

Optional items, all done:

  • test_deferred_reset_turn_describes_the_reused_process_directory now asserts turn_project_fallback is false. With bool(_fallback) changed to True in turn_admission.py it fails (checked, then reverted).
  • Proof line updated to this head, including test_summary_names_the_turn_project_after_a_mid_reply_pick.
  • Backwards compatibility line now says two summary keys and two props; the fallback paragraph says a pick made before a reload on a scratch fallback shows no pending badge.

Local on this head: 40 backend tests and 19 vitest tests pass; tsc, eslint, black and the line-cap check are clean. Re-requesting your review; the UX lane re-runs on the current body.

@JLargent42

JLargent42 commented Nov 16, 2026 •

Copy link
Copy Markdown
Contributor Author

Head 955114b, in answer to the Opus review on c8b1de1 and the brand gate.

  • Opus BLOCK (pick over a scratch fallback, then reload, showed no pending state): fixed. The turn pin now keeps the stored scratch folder, and turn_project_fallback is published only while project still names it. A pick moves project, the flag drops, and the client compares the pick with the server's directory, so it shows as pending after a reload too. Tests: the projection unit test (test_turn_project_pin_from_another_generation_names_no_turn) covers the flag dropping on a pick, and the new vitest case shows the pick as pending after a reload that follows a pick over a scratch fallback. The earlier "known gap" paragraph is gone from the description.
  • Source Gates brand check: the capture page comment is reworded and the fixture-folder lines in the capture script carry brand-ok, as the existing lines there do.
  • The 14 frames and the review reply from before are unchanged by this push (the capture page passes the fallback flag directly).

@JLargent42
JLargent42 force-pushed the fix/issue-20352 branch 2 times, most recently from a8c1794 to 8a48660 Compare November 16, 2026 20:26
@JLargent42

Copy link
Copy Markdown
Contributor Author

Head 8a48660, in answer to the GPT 6.1 review on a8c1794 (also rebased onto current main earlier, patch-id unchanged, to clear a Semgrep red that came from the stale base).

  • GPT BLOCK (pick B, then back to the scratch folder, leaves a false pending badge): fixed. useStagedProject now sets the pending baseline to the stored project whenever the server's flag is on, and to the server's directory otherwise, so returning to the scratch folder clears the badge. Vitest case drops the pending badge when the pick returns to the scratch fallback fails without the fix and passes with it.

@github-actions github-actions Bot added readiness: action required A blocking check or review needs attention and removed readiness: checking Automated validation is still running labels Nov 16, 2026
@KiroCrewCaptain

Copy link
Copy Markdown
Collaborator

Thanks for the follow-ups. On head 8a48660 the review found no blocking issue in this diff. Merge waits only on a red PR Readiness, and that red comes from main.

Earlier review items:

What the review checked on this head: the turn pin is written after the claim at all three admission sites. _running_turn_pin returns nothing for another turn generation or a slot that is not running. The scratch fallback flag compares the live project with the stored folder. Each of these has a test that fails when the line is reverted. The new slot field is registered in the facade, running-readers and golden tables and in the spec.

Red checks: Backend Tests shards 2 and 8 (Linux), shards 2 and 5 (Windows) and Coverage Gate fail in test_kas_orchestrator_memory.py and test_acp_runtime_load_session.py. Main's own push run fails the same tests after #36872 changed that resume path. This PR changes nothing under acp/. A maintainer will rerun the checks once main is fixed and then post the final review here.

Done well: the server pins the running turn's directory and tags the pin with its turn generation, so a pin left over from an earlier turn can never name the current one.

Optional:

  • Queued turn after a mid-reply pick (website/src/components/chat-input/stagedProject.tsx:97). The queue drain broadcasts the next turn's row before slot.task bumps the generation. In that window the client can still hold the previous turn's turn_project. The hook then overwrites the fresh baseline with the old directory and keeps it while later frames carry null. Consider adopting a server reading only once the prop changes after a turnKey re-take, and add a vitest case for that sequence.
  • No test covers the wiring from the slot to ChatInput (ComposerDockView.tsx:703, ChatPane.tsx:1411). One case in ChatPage.composerDock.test.tsx that seeds project: B, turn_project: A would catch a dropped prop.
  • The Proof line names head a8c1794, and the fallback branch has changed since then. Re-running the listed tests on this head and updating the line is a body edit only.

@KiroCrewCaptain
KiroCrewCaptain dismissed their stale review November 16, 2026 22:10

Withdrawn: every item in this review is fixed or answered on the current head (see the follow-up comment). Other holds on this PR are listed there.

The slot summary now carries turn_project, the directory the running turn's process works in, pinned at session claim with its turn generation (the reused process's cwd under a deferred reset), and turn_project_fallback for a hidden-scratch fallback. The composer prefers it over its start-of-response snapshot, so a reload, reconnect or move between running chats after a mid-reply pick names the reply's project, not the pick. Closes #20352.
@github-actions github-actions Bot added readiness: checking Automated validation is still running readiness: passed Eligible automated validation passed for the current revision and removed readiness: action required A blocking check or review needs attention readiness: checking Automated validation is still running labels Nov 16, 2026
@KiroCrewCaptain
KiroCrewCaptain enabled auto-merge (squash) November 17, 2026 01:14

@KiroCrewCaptain KiroCrewCaptain left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

On head cd7fa62 the review found nothing that blocks merge. This head is the same patch as 8a48660 rebased onto current main, and PR Readiness passes.

Earlier review items:

  • Stacked commit ahead of #31080: fixed. #31080 merged, and this head is one commit on top of main.
  • Visual evidence: fixed. The capture page has ?reload=1 and ?fallback=1 modes, the before and after frames are attached, and the UX and Design reviews pass on this head.
  • Reload-path frames: fixed, as above.

What the review checked on this head: the turn pin is written at all three admission sites (start of turn, hidden-scratch fallback, deferred reset). _running_turn_pin returns null for another turn generation or a slot that is not running. With no turnProject, useStagedProject behaves as it does on main. Each pin site and the newest pending-baseline rule has a test that fails when its line is reverted. The new field is registered in the facade, running-readers and golden tables and in the spec. Done well: the pin carries its turn generation, so a pin left over from an earlier turn reads as null and never as wrong data.

Optional:

  • The Proof line still names a8c1794, and the pending-baseline rule in stagedProject.tsx:102 changed after that. It also cites a bool(_fallback) mutation that does not appear in turn_admission.py. Re-running the listed tests on cd7fa62 and updating the line is a body edit only.
  • No test covers the slot-to-composer wiring (ComposerDockView.tsx:703, ChatPane.tsx:1423). One case in ChatPage.composerDock.test.tsx with project: B, turn_project: A would catch a dropped prop.
  • slot._turn_project_pin is written three times in turn_admission.py (1139, 1175, 1183). A single write after the deferred-reset block would be simpler, and it would also close a short window where a summary names the staged pick.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Keep the running reply project correct after a reload

2 participants