Repository navigation
refactor(ui): own activity and logbook state in Solid - #173771
Conversation
|
🦞👀 Pull request received. I will update this pull request when review starts. ClawSweeper review completeClawSweeper finished reviewing this revision. The review result is being finalized. |
Codex Review SummaryThis comment shows the latest Codex review activity on this pull request.
ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings. |
|
Codex review: needs changes before merge. What this changesMoves Activity coordination and Logbook lifetimes to scoped factories with Solid-owned presentation state. Example: Expand a Logbook card and enter “What should I work on next?”
Review scores
ProductKind: Refactor · Worth it: Yes · Fix scope: Complete Merge readiness⛔ Needs changes before merge - 1 item remains This PR is a useful, maintainer-directed refactor, but an introduced fixture error breaks all four Logbook browser layout cases. Priority: P3 Before merge
Findings
Agent review detailsHow this fits togetherControl UI owners consume Gateway session, presence, audit, and Logbook RPCs, then expose synchronous snapshots through reactive projections to Solid views. flowchart LR
U[User controls] --> V[Solid views]
V --> O[Scoped request owners]
O --> G[Gateway RPCs and events]
G --> O
O --> P[Reactive projections]
P --> V
L[View lifetime cleanup] --> O
Technical reviewBest possible solution: Keep the scoped-owner refactor and repair the browser fixture to use Do we have a high-confidence way to reproduce the issue? The changed source contains the undefined binding, and exact-head CI independently records the resulting four ReferenceErrors; no local tests were run. Is this the best way to solve the issue? The owner cutover keeps request admission synchronous, preserves existing reconciliation and lazy loading, and removes superseded controller paths; the fixture typo needs a focused correction. Full review comments:
Overall correctness: patch is incorrect AGENTS.md: found and applied where relevant. Codex review notes: model internal, reasoning medium; reviewed against 1b650393cea3. Provenance checked
TestingProof path: shipped entry point. SecurityNone. EvidenceAcceptance criteria:
What I checked:
PR surfaceSource -168, Tests -49. Total -217 across 22 files. Added test files: 0. View PR surface stats
Review metrics
LabelsLabel changes:
Label justifications:
Rating scale6/6 🦀 challenger crab · 5/6 🦞 diamond lobster · 4/6 🐚 platinum hermit · 3/6 🦐 gold shrimp · 2/6 🦪 silver shellfish · 1/6 🧂 unranked krab. Overall follows the weaker of proof and patch quality; ✨ marks media proof (a screenshot, video, or linked artifact) that directly shows the changed behavior. WorkflowClawSweeper edits this one comment on every review. Comment Reviewed October 16, 2026, 12:19 AM ET / 04:19 UTC. |
|
Merged via squash.
|
* refactor(ui): own activity and logbook state in Solid * test(ui): use the Logbook fixture date in browser status
What Problem This Solves
Activity still routes navigation and live-subscription reconciliation through generic controller invalidation. Logbook keeps its view and polling lifetime in a host-keyed WeakMap with a separate stop adapter.
User Impact
No intended behavior change. Activity routes, query ordering, inspector cancellation and recovery, presence expiry, and stream following remain intact. Logbook polling, day changes, expanded cards, question drafts, and reconnect resets keep their existing lifetime.
Why This Change Was Made
Replace Activity's page/query classes with scoped factories. Keep RPC admission synchronous, derive live entries from their owner, and put filters, expansion, and scrolling state in Solid. A stream ref replaces the DOM search. Logbook owns its polling cleanup; keyed card owners hold expansion, and connection epochs remount the bundled view instead of calling through the host map. The bundled import stays lazy.
Across touched production files: 3,452 → 3,284 LOC (-168). Tests: 3,029 → 2,980 (-49). Controller-pattern references: 37 → 0;
createEffect: 11 → 10;untrack: 5 → 4. TextualaddEventListenerreferences increase 7 → 9 because existing computed registrations become explicit; actual visibility/pagehide/pageshow registrations are unchanged and paired with cleanup. Counts include imports and exclude AbortController.Evidence
No Solid diagnostics appeared in the focused tests. No passing suite was repeated. Full UI coverage is requested with
ci:full; no local E2E suite or parity run was used.The inspected, synthetic 1280×900 dark captures preserve content and layout. The expanded live view is pixel-identical; the sessions and Logbook captures have 132 and 108 differing pixels respectively around small text/icons. Contact sheets are ordered Activity sessions, live activity, and Logbook.
CI fixture correction
Full CI run 38848698560 exposed an undefined
todayshorthand in the Logbook browser fixture. The four browser cases and UI-pages test typecheck failed on that same typo; this was caused by this PR. The fixture now uses its existingdayvalue. All four browser cases and the UI-pages test typecheck pass locally. Production code, bundle measurements, and captures are unchanged.