Repository navigation
refactor(ui): use a draft store for input dialog status - #180272
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 maintainer review before merge. What this changesThis PR replaces the input dialog’s copied status-object signal with a Solid draft store and adds abort/successor isolation coverage. Example: Save the session name “Renamed original” while its write remains pending.
Review scores
ProductKind: Refactor · Worth it: Yes · Fix scope: Complete Merge readiness✅ Ready for maintainer review This PR preserves the dialog’s behavior while adopting draft-store updates; the earlier pending-state finding is resolved, and no actionable code defects remain. Priority: P3 Before mergeNone. FindingsNone. Agent review detailsHow this fits togetherThe shared Control UI input dialog accepts caller-owned submission callbacks and presents validation, pending state, errors, and cancellation through the existing modal host. flowchart LR
A[Session or group action] --> B[showInputDialog]
B --> C[Promise modal host]
C --> D[Input dialog view]
D --> E[Caller submission]
E --> F[Draft store presentation]
F --> D
Technical reviewBest possible solution: Keep the local draft store with the existing synchronous admission flag, modal settlement owner, and caller-owned submission lifetime. Do we have a high-confidence way to reproduce the issue? This is a behavior-preserving refactor; source comparison confirms the previous deferred-busy trigger has been removed, and no target code was executed during review. Is this the best way to solve the issue? The patch follows the repository’s structured-local-state guidance and keeps admission, mutation, and modal settlement with their existing owners. AGENTS.md: found and applied where relevant. Codex review notes: model internal, reasoning medium; reviewed against f2fccc2d677c. Provenance checked
TestingProof path: shipped entry point. SecurityNone. EvidenceWhat I checked:
Likely related people:
PR surfaceSource +7, Tests +31. Total +38 across 2 files. Added test files: 0. View PR surface stats
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 HistoryReview history (1 earlier review cycle)
Reviewed October 22, 2026, 1:41 AM ET / 05:41 UTC (Revision 2). |
|
The synchronous pending-state finding is fixed on current head The earlier cross-agent and HTML-publication failures did not recur in the following full run on @clawsweeper re-review |
|
🦞👀 Re-review progress:
|
|
Merged via squash.
|
What Problem This Solves
The shared input dialog copied its submitting/error status object for each update. Use a Solid draft store for that local presentation state while preserving synchronous duplicate-submit admission and the existing plain async submission lifetime. Controls disable with the admitted submission; rejected writes keep the draft editable and restore input focus.
The pending-attempt test retains its single-flush assertion, and a new regression aborts a pending prompt, opens a successor, and rejects the old write. The successor must remain editable with no leaked error. No second mutation owner, request, cancellation path, or navigation transaction is introduced.
Evidence
0671880a: scoped-clean, no actionable findingsd563; the rendered component and regression test are byte-identical after the merge-only integration. Original base images retained.0671880avs current head: passed, zero violations. Startup 316,060 → 316,057 B gzip / 7 JS requests; CSS 40,894 B / 1 request unchanged; chat 1,435,747 → 1,435,742 B; new session 1,014,063 → 1,014,049 B. Raw sizes and request counts unchanged.0671880abase and current head both report the same 13 unused heartbeat paths outside UI. Complete output byte-identical, SHA-2560ec893790beb14caa4f097a177380749978d9ebed28d7a75700fd3df1a7af3fd; no new unused paths.591751cb9db7, full run 39728328622, passed withci:full: all UI units, all 9 browser shards, both real-Gateway shards, type/lint/security and performance checksCurrent main integration includes the settings-focus repair in #180218. The previous full CI reported that focus failure and the Markdown table expansion case. A targeted run on its exact main parent
f25a10e9reproduced the focus failure while the table case passed; no inherited exemption is claimed for the table case. The current full run passed both the settings-focus and table-expansion cases. The earlier immediate disabled-state failure is covered by the restored single-flush assertion. Node is used only for targeted Playwright proof; unit tests use the pinned Bun runtime. No cloud/Testbox lease.Solid 2 checklist and size
The one production file uses createStore 0 → 1, copied status-object signals 1 → 0, total signal calls 2 → 1, and retains the scalar input draft signal. Actions and optimistic flags remain 0 → 0. Native handler-binding defects, component teardown, async read loaders, manual imports, JSX factories, context rethrow wrappers, sibling-loading gaps, and owner API escapes remain 0 → 0. The existing
untracksnapshot remains 1 → 1 because a prompt retains the request/options it opened with.Checklist item 4 retains one named survivor: this generic confirmation prompt publishes immediate disabled/error state around its existing owner-owned submission. A pending presentation action delayed that contract in the tested candidate. This does not create an exception for other component mutations.
Production LOC 133 → 140 (+7), from explicit draft writes replacing object snapshots. No dependency, public contract, route, tag, selector, or style changes.
Screenshots
Synthetic data only, 1280×900.