Repository navigation
fix(ui): wait for restored draft before clearing - #133575
Conversation
|
🦞👀 Pull request received. I will update this pull request when review starts. |
|
Codex review: needs maintainer review before merge. Reviewed August 30, 2026, 6:44 PM ET / 22:44 UTC. ClawSweeper reviewWhat this changesThe PR moves the Control UI draft-indicator scenario into a dedicated E2E file and waits for restored and cleared composer values before asserting draft-badge removal. Regression provenancePossible regression — probable (reviewed change; failure trace). No predecessor PR is attributed. Merge readinessThis is a clean, test-only repair for a reported Control UI E2E race. It remains open because it is maintainer-authored and carries the protected Priority: P3 Review scores
Verification
How this fits togetherThe Control UI restores a browser-local composer draft when a session becomes active and exposes draft presence in the sidebar. This E2E test verifies that clearing a restored draft removes that sidebar indicator across session navigation. flowchart LR
A[Saved browser draft] --> B[Session route opens]
B --> C[Chat composer restores text]
C --> D[Composer state settles]
D --> E[Sidebar draft indicator]
E --> F[Navigation assertion]
Before merge
Agent review detailsSecurityNone. PR surfaceTests +18. Total +18 across 2 files. View PR surface stats
Review metrics
Merge-risk optionsMaintainer options:
Technical reviewBest possible solution: Retain the dedicated browser-level regression scenario and its render-settlement checks so restored-draft clearing remains reliably covered without changing product behavior. Do we have a high-confidence way to reproduce the issue? Yes, from source and the supplied CI failure: the former scenario cleared the composer before restored state had settled, while the revised scenario waits at that boundary. This read-only review did not rerun the test. Is this the best way to solve the issue? Yes. Reusing the existing two-poll render-settlement helper addresses the asynchronous test race at the browser-visible boundary without coupling the test to storage internals or changing production code. AGENTS.md: found and applied where relevant. Codex review notes: model internal, reasoning high; reviewed against ca90c2488899. LabelsLabel justifications:
EvidenceWhat I checked:
Likely related people:
Rating scale
Overall follows the weaker of proof and patch quality. Workflow
History |
1419da0 to
15553b6
Compare
|
ClawSweeper before-merge item addressed:
|
|
Merged via squash.
|
…cked-delivery * origin/main: fix(ui): wait for restored draft before clearing (openclaw#133575) fix(deps): update fast-uri security patches (openclaw#133572) test: reduce workflow sanity fixture cleanup time (openclaw#133588) fix(media): normalize detected Matroska MIME (openclaw#133383) refactor(docker): retire ClawDock shell helpers (openclaw#133594) perf(browser): reuse snapshot refs and screenshot metadata (openclaw#133598) perf: load web chat history in larger, faster batches (openclaw#133565) fix(plugins): keep bundled plugins bundled when selected by plugins.load.paths (openclaw#133584) test: isolate shared /tmp session-store paths in runner and health suites (openclaw#133568) fix(cron): avoid no-op schedule repair writes (openclaw#133552)
What Problem This Solves
Resolves a release-validation failure where the Control UI session-management E2E could leave a restored draft badge visible after clearing the composer on a slow CI runner.
Why This Change Was Made
The test now waits for the retained composer value to finish restoring, then waits for the cleared form state and draft-badge removal before navigating. The focused scenario lives in its own draft-indicator E2E file so the existing sidebar suite remains below the enforced line cap. This is a test-only synchronization repair; production behavior is unchanged.
User Impact
No product behavior changes. Main and Full Release Validation can reliably verify the existing restored-draft clearing behavior.
Evidence
af8dad8e9e32d50088064702ee1614ea8d7687d9failed insession-management.sidebar.e2e.test.tsbecause the draft badge count remained1after an empty fill raced retained-composer restoration:11/13: 26 files and 110 tests passed.check-lint-core-4stripe: passed.[email protected]because the sparse GWT lacked its normalui/node_moduleslink; rerunning the failed typecheck with the current UI workspace dependency ([email protected], bundled declarations) passed.git diff --check: passed.gpt-5.6-sol, high): scoped clean, no actionable findings.+0/-0; tests:+97/-79(net+18).