Repository navigation
fix(ui): preserve dialog feedback through save retries - #180729
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 changesThis PR derives input and goal-dialog feedback from completion promises while retaining native fields and synchronous submission admission. Example: Creating “Project alpha” returns “A group with this name already exists.”
Review scores
ProductKind: Refactor · Worth it: Yes · Fix scope: Complete Merge readiness⛔ Needs changes before merge - 1 item remains Keep open: this maintainer-directed refactor has one focused repair remaining—two existing consumers fail because their assertions precede the new saving publication. Priority: P3 Before merge
Findings
Tests
Agent review detailsHow this fits togetherControl UI callers supply drafts and submission callbacks to modal dialogs; existing owners admit writes and settle the modal, while Solid presents saving, validation, errors, and focus. flowchart TD
A[Session and Goal callers] --> B[Native modal host]
B --> C[Synchronous submission admission]
C --> D[Existing write owner]
D --> E[Completion receipt]
E --> F[Solid saving and feedback]
F --> B
Technical reviewBest possible solution: Preserve receipt-based feedback and update both affected consumer tests to observe committed saving and recovery state. Do we have a high-confidence way to reproduce the issue? No new current-main product defect is established; exact-head CI independently records two consumer-test failures caused by the changed saving-publication timing. Is this the best way to solve the issue? The completion-receipt approach uses existing owners and preserves separate validation results and rejected errors, but its timing change must be carried through the existing consumers. Full review comments:
Overall correctness: patch is incorrect AGENTS.md: found and applied where relevant. Codex review notes: model internal, reasoning medium; reviewed against f0849a116679. Provenance checked
TestingProof path: in-process harness. SecurityNone. EvidenceAcceptance criteria:
What I checked:
PR surfaceSource +55, Tests +83, Docs +64. Total +202 across 5 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 22, 2026, 11:50 AM ET / 15:50 UTC. |
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: bc445da1c8
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
| <Show | ||
| when={props.presented && editAttempt()?.identity === goalIdentity() && editAttempt()} | ||
| keyed |
There was a problem hiding this comment.
Clear stale edit failures when the goal scope changes
When dialog preparation fails, editAttempt permanently retains the rejected promise and this condition merely hides it while another identity is active. If the retained component moves from session/goal A to B and later returns to A, the old alert reappears despite no edit attempt occurring in the current visit. Clear the attempt when goalIdentity() changes or associate it with a per-presentation generation rather than a reusable identity.
AGENTS.md reference: ui/AGENTS.md:L16-L19
Useful? React with 👍 / 👎.
|
Merged via squash.
|
* fix(ui): preserve dialog feedback through save retries * test(ui): await rename submission presentation * fix(ui): surface goal dialog preparation failures
What Problem This Solves
Input and goal-edit dialogs copied asynchronous failures into local presentation state. The goal editor also left a failed dialog preparation invisible and unhandled. A second click during pending preparation must not replace the first admitted operation's failure receipt.
User Impact
Failed saves retain the draft, focused input and validation feedback. A failed goal-editor preparation now shows an alert beside the retained controls and permits a fresh attempt. Existing native dismissal, duplicate-submit admission and scope retirement remain intact.
Why This Change Was Made
Use co-written optimistic saving flags and narrow
Erroredslots derived from admitted completion promises. Expected validation strings remain ordinary results; rejected promises reach the boundary. The native input remains outside the error slot, witharia-invalidderived from the same receipt. Record goal preparation inside its existing admission guard so duplicate clicks cannot hide its result.The shared recipe consolidates this audit's recurring patterns: validation receipts, initial-only
loadingValue, retained status reads withlatest, repeated boolean outcomes, native attribute boundaries, preparation failures, and native-root lazy error handling. It also documents the observed foreign-root and independent-option settlement exceptions. Domain owners, host tags, classes and lazy boundaries are unchanged; no dependency was added.Evidence
pnpm tsgo:ui; targeted lint, format and diff checkpnpm ui:build; strict performance checkc5650f3a5e59d6523c913a8ebfff2b787cf58435src/infra/heartbeat-active-hours.ts,src/infra/heartbeat-wake-policy.ts; no UI findingProduction LOC: 408 → 494 (+86), needed for retained-field validation and error receipt boundaries. All changed tests: 1,514 → 1,634 (+120). Recipe: 498 → 575 (+77), including consolidated audit patterns shared by the other focused fixes.
Erroredboundariesaffects,refresh,Loading on, outside-hold deviationsTwo plain synchronous admission latches remain authoritative; they are not presentation saving flags. The existing
untrackkeeps prompt options fixed for the prompt lifetime. No new effects, listeners, queries, flushes, cleanup hooks or owner APIs were added. These counts cover this focused family; the coordinator owns the whole-scope audit table.Full UI CI is requested with
ci:full. Run39805746766identified the immediate sessions disabled assertion; run39809900182identified the native pending-input timing assertion. Both named consumer tests were repaired and passed locally. The latter run passed all nine UI E2E shards and both real-Gateway shards. Final-headci:fullrun 39817758807 completed successfully forbc445da1c8f14d1df306c513e6890e2356f70b9a, including all selected unit/lint/type checks, all nine UI E2E shards and both real-Gateway shards.Inspected synthetic screenshots