Repository navigation
fix(dashboard): re-read a root session's Overview when its work ledger moves - #26953
Conversation
UX Review (Opus 5.5) — ✅ PASSUX-level review of UX-Verdict: PASS Nothing to check. The diff adds and changes no visible control, string or layout. It only changes when an Overview that is already open re-reads its data, so it needs no screenshot. [UX-REVIEWED] 7aab5fa Description read[DESCRIPTION-READ] dba1fab1720aa94392314e87240880f125eff273a7ab72c7ec6246137a5c8ff9 That sha256 names everything this verdict read: the PR description, plus the 3 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 |
Design Review (Opus 5.5) — ✅ PASSDesign-level review of Design-Verdict: PASS Nothing blocks: the fix reuses the slot frames that already fire on a ledger write, and the existing owner-checked page read does the refresh, so the gateway contract is unchanged. Notes
[DESIGN-REVIEWED] 7aab5fa Description read[DESCRIPTION-READ] bb8850cf0350e1ec5ee14185cd0e5c54b024053ff9795666d6e406fcef866218 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 |
First Principles Review (Opus 5.5) — ✅ PASSPremise-level review of First-Principles-Verdict: PASS Nothing blocks. The re-reads come from the slot frames that already fire on a ledger write (#21915). The watch-set entry is what lets those frames reach a tab that has no work board mounted. What this change shipsInventory (4 items) — 4 justifiedIntent: a root session's open Overview shows a newly recorded work item without the panel being reopened. This is a FIX.
[FIRST-PRINCIPLES-REVIEWED] 7aab5fa Description read[DESCRIPTION-READ] e10709dacfac101f9da81e0c10fb0be3015f6f8dca52d679cc02c09f4bb460fe That sha256 names the PR description this verdict read. Recompute it with |
Opus 5.5 Review — ✅ no blocking findingsReviewed Verdict parsed from the review's SHA-scoped output markers for commit False positive or not applicable? A repository writer can comment: |
GPT 6.1 Review — ✅ no blocking findingsGPT 6.1 completed its review of This comment is updated in place on each push. Review detailsNo findings. False positive or not applicable? A repository writer can comment: |
9065ed9 to
b80ea8f
Compare
|
self-added: yes
|
…r moves A root session's side panel Overview kept its old board after the session recorded a work item, until the panel was reopened or the 60 s fallback read. A work-ledger write reaches the tab only as a slot_projection or slot_fold frame, which re-read the command-center work board but never the session page, and a tab that watches boards did not list an open Overview, so the gateway did not even send it those frames. The fold watch now lists the slot of every mounted session page, and both slot frames re-read the open session page of the frame's slot and of every slot it was created under (the same team roots the work board re-reads), through refreshDashboardReads so a burst of frames keeps one read in flight. Closes #21915
b80ea8f to
7aab5fa
Compare
|
[operator: bolichen97] Backend Tests (3.12, 8) and the Coverage Gate (failing closed on it) are main's red, not this PR's: test/test_sandbox_protected_name_holds.py::TestLeafOnlyPopulationIsRecorded fails the same way on main push run https://github.com/kirodotdev/KiroCrew/actions/runs/41284924233, and this diff touches only website/ and one RFC. Fix in flight: #26983. Rebasing once it lands. |
KiroCrewCaptain
left a comment
There was a problem hiding this comment.
Tier 1 auto-approve: fix (7 files). Criteria: no conflict, no requested changes, security path denylist clean, design-doc gate clean, security checklist all-NO, no reviewer-lane findings, readiness signal fresh for this head SHA, declared category matches the diff. Category: frontend fix; a root session's open Overview now re-reads when a slot_projection or slot_fold frame shows its work ledger moved, and the fold watch set includes mounted Overview pages, with tests. Spec files changed as a ride-along (a minority of the diff on both file count and changed lines), not reviewed as a design decision: docs/request-for-change/rfc-fold-delta-push.md.
Problem / Motivation
Goal: A root session's side panel Overview shows a newly recorded work item as soon as the session writes it, without reopening the panel.
A template page such as
goal-boardkeeps showing "No item on this board yet" after the Conductor records an item in the same chat. Reopening the panel shows the item, so the page and the fold are right; only the refresh is missing (seen on #21889).Why it matters
The Overview is the conductor's live board. Anyone using Crew Mode watches it to see what the crew is doing, and today it can sit on an empty or old board for up to the 60 s fallback read (and longer while the tab is in the background), which reads as "nothing is happening".
Not a goal
member_projection/dashboard_value_written.What changed (motivation → approach → change)
Symptom: an open Overview keeps its old board after a work-ledger write.
Root cause: a ledger write reaches the tab only as a
slot_projectionframe, or aslot_folddelta for a tab that applies deltas. Both handlers re-read the command-center work board but never the session page. A tab that declared the fold-watch capability also only listed mounted work boards infold_watch, so an Overview with no work board beside it did not get the frames at all.Change:
foldWatch.ts: the watch set also lists the slot of every mounted root session page.useWebSocket.ts+serverState.ts(handleSlotFoldMoved): both slot frames re-read the open session page of the frame's slot and of every slot it was created under (the same team roots the work board uses, so a worker's report moves its conductor's page). ThroughrefreshDashboardReads, so a burst keeps one read in flight; slots with no cached page are skipped. Aslot_foldthe work board callsstalestill re-reads the page: the board's own 10 s poll can land that revision first, which says nothing about the separately cached Overview.I took the client path the issue names over a new gateway frame: the slot frames already fire on exactly this write, and the page reads stay owner-checked by the existing route.
Backwards compatibility
Compatible: a tab only re-reads a page it already shows, and only lists more slots in
fold_watch; the gateway accepts any slot there.Removes nothing: the diff only adds a re-read and a watch entry.
Tests
src/test/useWebSocket.sessionDashboardRefresh.test.ts(new, through the real hook and socket): aslot_projectionfor the root re-reads its open Overview; a frame for a worker created under it does too, and one for an unrelated slot does not; aslot_foldsnapshot_neededre-reads it, and so does a delta whose revision the work board already polled (red with astaleguard on the call).src/hooks/websocket/foldWatch.test.ts: a mounted Overview's slot is in the watch set and leaves it on unmount; an unobserved one is not.src/test/useWebSocket.ownership.test.ts: lists the newfoldWatch.ts -> serverState.tsimport edge (forSESSION_DASHBOARD_QUERY_PREFIX).Red/green: with only the new tests on
origin/mainsources, 4 of 8 fail (the 3 hook tests and the watch-set test); all pass with the fix. The two new files pass 5 runs with--sequence.shuffle(seeds 1-5).vitest relatedover the changed files (537 files) passes;tsc -p tsconfig.app.json, eslint and the repo semgrep rules pass.Proof: not provable -- frontend test (prove.py runs Python only)
Manual verification
N/A - unit coverage sufficient: the hook tests drive the real WebSocket handler and react-query cache, which is the whole path between the frame and the page read.
Screenshots / video
Why no screenshot: the Overview renders exactly as before; only when it re-reads changes, which the hook tests cover.
Related Issues
Closes #21915
Sibling sweep
Swept:
git grep -n "SESSION_DASHBOARD_QUERY_PREFIX\|MEMBER_DASHBOARD_QUERY_PREFIX" -- website/srcSibling: website/src/hooks/websocket/serverState.ts -- not affected -- member pages already re-read on member_projection and dashboard_value_written
Pattern harvest
Not generalizable: the one cache key a slot frame failed to reach; the other readers of slot folds (work board, cards) already re-read on it.
Checklist
feat|fix|docs|style|refactor|perf|test|chore|ci|build|revert: ...)