Repository navigation
refactor(ui): let session chips consume their place owner - #177641
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 changesThe New Session chips consume the existing place owner directly instead of receiving three intermediate prop objects. Example: Choose New worktree and enter release/next as the starting branch.
Review scores
ProductKind: Refactor · Worth it: Yes · Fix scope: Complete Merge readiness⛔ Needs changes before merge - 3 items remain Keep this useful maintainer-directed refactor open; two missed test-consumer migrations cause confirmed CI failures. Priority: P3 Before merge
Findings
Tests
Agent review detailsHow this fits togetherThe Control UI’s New Session page projects draft placement into Where, Project, and Checkout controls; selections return to the existing draft-place and browser owners. flowchart LR
A[New Session page] --> B[Place controls projection]
B --> C[Where Project Checkout chips]
C --> D[Shared session picker]
C --> E[Draft place owner]
D --> F[Draft browser owner]
E --> F
Technical reviewBest possible solution: Keep the direct-owner refactor and complete the remaining chip and picker test-consumer migrations. Do we have a high-confidence way to reproduce the issue? No product bug is claimed; source inspection and exact-head CI independently establish the stale test-consumer failures. Is this the best way to solve the issue? The smallest complete refactor removes the intermediate DTOs while retaining the existing state owners, memoized selection facts, and all consumer assertions. Full review comments:
Overall correctness: patch is incorrect AGENTS.md: found and applied where relevant. Codex review notes: model internal, reasoning medium; reviewed against d9bee70655af. Provenance checked
TestingProof path: unit tests only. SecurityNone. EvidenceAcceptance criteria:
What I checked:
PR surfaceSource -169, Tests +147. Total -22 across 12 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 19, 2026, 3:35 PM ET / 19:35 UTC. |
|
Merged via explicitly authorized admin squash with attributed pre-existing CI failures.
|
…77641) * refactor(ui): let session chips consume their place owner * test(ui): mount placement controls with canonical owners * test(ui): update new-session focus fixture
What Problem This Solves
New Session chips copy existing draft-place state and operations into three one-producer prop objects, duplicating data ownership and callback plumbing.
User Impact
No user-visible change. Target, project and checkout chips keep the same controls, keys, draft state, and placement behavior.
Why This Change Was Made
Read the existing place owner from chip renderers and remove the intermediate DTOs and assembly memos. Parent selection memos still resolve each input once. No new state owner or abstraction.
Production LOC: 2,095 → 1,926 (−169) across eight files. Test fixtures now use the existing owner contract. No markup/class/selector or styling changes; the before/after static class and id attribute multisets are identical.
Evidence
Proof captured before branch separation with the same code; only mechanical lint fixes followed. Relevant input files and dependency pins are unchanged on the new base. Broad proof runs in PR CI with ci:full for the shared picker/overlay behavior. No startup import or lazy-boundary change.
CI fixture repair
The initial head left the browser placement fixture on the retired chip props. All six viewport/direction cases failed with
cloudSelectionundefined, and the UI test typecheck found the same stale contract. The fixture now shares the existing owner-backed params and keeps its viewport, accessibility and folder-selection assertions. The repair removes 31 test lines; production remains −169 lines.Proof: the six browser cases pass on the pinned Bun runner,
pnpm tsgo:uiand the UI-page test typecheck pass, type-aware lint passes, and independent review found no actionable issue. A final type-aware lint correction usesvi.spyOndirectly without changing behavior.Full final PR accounting: production −169, tests/fixtures +113, whole PR −56 lines. Fresh lane scope baseline: 222,085 production lines (217,240 handwritten + 4,845 generated); target 4,442 removed.
Completed CI attribution
CI run 39320330189 completed for this exact head. Every selected runtime suite, including all Control UI and real-Gateway shards, passed. Only core typecheck and lint fail: missing
createDeferredCoreatsrc/gateway/local-http-probe.test.ts:154, resulting implicit-any at line 178, andtypescript(prefer-promise-reject-errors)at line 178.The actual tested merge
f37a1cce56656e8eb4bbfb598c4b07a71c7e35f1has main baseline0548086d6a95525d7bad7f1905d2ae8c8d2de3efand this exact PR head as ordered parents. Its failing test is byte-identical to that baseline and the literal main reproduction at2cc639d70234, where the exact type and lint diagnostics reproduce. Main now contains the one-line import repair 08e32fdb4df0. Landing uses the documented inherited-failure route; no claim that failed CI was green.