Repository navigation
fix(ui): preserve app input when reopening dashboard panel - #169441
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: needs maintainer review before merge. What this changesThis PR publishes MCP App activity and visibility together so reopening the Dashboard panel preserves unsaved input. Example: Type “Keep this unsaved dashboard note,” minimize Dashboard, and reopen it while the lease remains valid.
Review scores
ProductKind: Bug fix · Worth it: Yes · Fix scope: Complete Regression provenanceRegression provenance — verified: source commit Merge readiness✅ Ready for maintainer review Keep open: this PR repairs a dashboard draft-loss regression still present on current main; the focused patch has no actionable findings. Priority: P2 Before mergeNone. FindingsNone. Agent review detailsHow this fits togetherThe Control UI board cell translates panel activity and MCP lifecycle observations into rendering decisions that retain or retire the embedded app iframe. flowchart TD
A[Dashboard panel activity] --> B[Board widget cell]
C[MCP lifecycle and visibility] --> B
B --> D[Coherent render snapshot]
D --> E[MCP App content]
E --> F[Retained or retired iframe]
Technical reviewBest possible solution: Land the coherent snapshot correction while preserving the existing lifecycle, expiry, reconnect, and offscreen policies. Do we have a high-confidence way to reproduce the issue? The current-main source exposes the mixed activity/visibility teardown path, and the supplied browser evidence reports the exact draft-loss reproduction; this review did not execute it independently. Is this the best way to solve the issue? The patch repairs publication consistency at the existing cell snapshot rather than weakening teardown or introducing another retention owner. AGENTS.md: found and applied where relevant. Codex review notes: model internal, reasoning medium; reviewed against d0df645f6601. Provenance checked
TestingProof path: shipped entry point. SecurityNone. EvidenceWhat I checked:
Likely related people:
PR surfaceSource +2, Docs +2. Total +4 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 Reviewed October 11, 2026, 7:42 PM ET / 23:42 UTC. |
|
Maintainer override (Ayaan approved landing): the only red job on this head (465e755) is
|
The debug overlay port (#168805, d64ce70) moved its implementation to TSX; point stale-chunk fault injection at the emitted module instead of the erased TypeScript re-export facade. This restores all five System busyness frame cases without changing production code or weakening their assertions. Model the Meetings summary-generation RPC with a held, typed interim result. The old fixture returned an invalid empty object, causing the Solid reader to throw on session.title and retain its previous tab. Keep all original Summary, speech, interim-notes, and final-notes assertions. Strengthen Board's existing inactive-app regression to reject teardown. The production repair landed concurrently in #169441 (ad69564); adopt that smaller owner fix and preserve this independent regression assertion. Record all three migration lessons. Proof: 164/164 tests across every Board and Meetings unit/browser file; Board MCP E2E 5/5, lazy recovery 21/21, Meetings E2E 4/4. Original Board and Meetings failures reproduced before the repairs. UI typecheck, targeted lint/format, assertion safety and line-budget checks pass. Independent review has no actionable findings. Base/head builds pass; strict performance has the same inherited chat-boot request violation (36 > 35). Testbox did not admit within about ten minutes, so proof ran locally with one worker.
Related: #168887, #169439, #169441 ## What Problem This Solves Fixes missing nested chat activity and stale media resources after the Solid transcript migration, restoring 20 failing `checks-ui` cases inherited by unrelated PRs. ## User Impact Expanded activity shows its nested calls again. Parked image and video previews release their resources and reconnect through the existing scope-checked caches. No settings, protocol, storage, or migration changes. ## Why This Change Was Made Keep deferred tool-card children inside their existing Lit-owned range instead of creating nested Solid roots that are retired while parked. Bind image and video resource lifetimes to the existing Solid presentation context. Update lifecycle fixtures to await the documented deferred Solid disposal boundary without removing or weakening any assertions. Checked steipete's open UI PRs before editing. #169442 overlaps the activity headline, not these repairs. #169346 has green UI results on an older tree, but its head lacks the later bridge changes and does not repair these current-main failures. No overlap with Pash/Sarah changes. ## Evidence - Baseline `a9b40cf325e`: all **20 reported failures reproduced** across eight files (116 other cases passed). - Rebased onto current main, including #169439 and #169441: **190 tests passed across 10 files**, including all 20 failures plus media handoff and native media siblings. - `pnpm tsgo:ui`: passed. - `pnpm run tsgo:test:ui`: all UI shards passed. - Changed-file oxlint/oxfmt, line-cap ratchet against `origin/main`, and `git diff --check`: passed. - Independent P0–P2 review: no actionable findings. - Original failing CI: [shard 2](https://github.com/openclaw/openclaw/actions/runs/38184982892/job/114605449166), [shard 3](https://github.com/openclaw/openclaw/actions/runs/38184982892/job/114605449173), and [image admission run](https://github.com/openclaw/openclaw/actions/runs/38184424359). ### Expanded activity, before and after Captured from the same Chromium fixture and inspected. Before: the opened parent has no nested calls. After: the calls render and the original height/collapse assertions pass. | Before | After | | --- | --- | |  |  | |  |  | <details> <summary>Per-test disposition: all 20 fixed</summary> | Test file | Previously failing cases | Status | | --- | --- | --- | | `chat-activity-layout.browser.test.ts` | Expanded height and collapse, standalone | fixed | | `chat-activity-layout.browser.test.ts` | Expanded height and collapse, inline | fixed | | `chat-activity-layout.browser.test.ts` | Opened lone step with routine nested calls | fixed | | `chat-activity-disclosure.test.ts` | Settled completed step with routine nested calls | fixed | | `chat-position-rail.test.ts` | Focused previews, pointer exit, removal, and session reset | fixed | | `chat-message-attachment-admission.test.ts` | Stale admission after source replacement/disconnect | fixed | | `chat-message-text-chip-admission.test.ts` | Stale comment observations | fixed | | `chat-message-text-chip-admission.test.ts` | Stale paste observations | fixed | | `chat-transcript-invalidation.test.ts` | Hidden video preview, rendered parent | fixed | | `chat-transcript-invalidation.test.ts` | Hidden video preview, parked parent | fixed | | `chat-message-media-lifecycle.test.ts` | Guarded managed image reconnect | fixed | | `chat-message-image-admission.test.ts` | Loaded assistant image remount | fixed | | `chat-message-image-admission.test.ts` | Loaded assistant image reconnect | fixed | | `chat-message-image-admission.test.ts` | Detached image after authToken change | fixed | | `chat-message-image-admission.test.ts` | Detached image after sessionKey change | fixed | | `chat-message-image-admission.test.ts` | Detached image after agentId change | fixed | | `chat-message-image-admission.test.ts` | Detached image after connectionEpoch change | fixed | | `chat-message-image-admission.test.ts` | Detached image after resourceBasePath change | fixed | | `chat-message-image-admission.test.ts` | Detached image after policyKey change | fixed | | `chat-message-image-admission.test.ts` | Detached image after expiry | fixed | No reported case was already fixed on the captured main baseline. The managed-image remount sibling already passed and continues to pass. </details> Two-way door: reverting restores the prior rendering/resource behavior without changing persistent state. Blast radius is Control UI chat activity disclosure and image/video preview lifecycles. Co-authored-by: Ayaan Zaidi <[email protected]>
…169441) ## What Problem This Solves Fixes: unsaved input in a Dashboard MCP App disappears when the side panel is minimized and reopened. ## User Impact Loaded apps keep their local state through the panel transition. Existing offscreen teardown, lease expiration, reconnect, and lazy first-load policies remain unchanged. No configuration or migration is required. ## Why This Change Was Made The Solid board port (openclaw#168871) let the content renderer see the new active flag before the lifecycle published its new visibility. Reopening briefly looked like an active offscreen app and tore down its iframe. The existing cell snapshot now publishes activity with the observed visibility instead of mixing two revisions. No new state owner or retention exception is introduced. No overlap with Pash/Sarah changes. ## Evidence On current main `11f576b23cf70615ca4504eb12fdba93591b9c8f`, the production-bundle E2E run of the three reported files had **1 failure / 17 passes**: the board retention case received an empty string instead of `Keep this unsaved dashboard note`. All nine history-prepend cases and all four chat-scroll cases already passed; main's `13f59c6281a` repairs their history/follow owners, so they are not duplicated here. With this fix, the unchanged complete `board-mcp-app.e2e.test.ts` passes **5/5**, including retention through split, expanded, minimized, and inactive states; reconnect replacement; renewal; and offscreen lazy loading. The retention case takes 2.797 s, and the full bundled command takes 23.19 s. No tests, expectations, retries, or timeouts changed. A separate original-source capture reproduces the empty-note failure in 18.065 s. Command: `node scripts/run-vitest.mjs run --config test/vitest/vitest.ui-e2e.config.ts --configLoader runner --project ui-e2e-bundled --maxWorkers=1 ui/src/e2e/board-mcp-app.e2e.test.ts` Focused checks: all **14** board MCP lifecycle unit cases pass, including active-offscreen teardown, inactive retention, expiry, and reconnect. `pnpm tsgo:ui`, scoped oxlint, oxfmt, the line-cap ratchet against `origin/main`, and `git diff --check` pass. Independent Codex review of the final diff is scoped-clean through P2. ### Before and after reopening Both screenshots use the same synthetic app. Before, the iframe restarts at its initial scroll position and loses the note. After, it remains at the note with its input intact. Two-way door: reverting restores the old panel-transition behavior. Blast radius is the board MCP App renderer; no stored data, Gateway behavior, or channel delivery changes.   Co-authored-by: Ayaan Zaidi <[email protected]>
The debug overlay port (openclaw#168805, 5a27399) moved its implementation to TSX; point stale-chunk fault injection at the emitted module instead of the erased TypeScript re-export facade. This restores all five System busyness frame cases without changing production code or weakening their assertions. Model the Meetings summary-generation RPC with a held, typed interim result. The old fixture returned an invalid empty object, causing the Solid reader to throw on session.title and retain its previous tab. Keep all original Summary, speech, interim-notes, and final-notes assertions. Strengthen Board's existing inactive-app regression to reject teardown. The production repair landed concurrently in openclaw#169441 (43865da); adopt that smaller owner fix and preserve this independent regression assertion. Record all three migration lessons. Proof: 164/164 tests across every Board and Meetings unit/browser file; Board MCP E2E 5/5, lazy recovery 21/21, Meetings E2E 4/4. Original Board and Meetings failures reproduced before the repairs. UI typecheck, targeted lint/format, assertion safety and line-budget checks pass. Independent review has no actionable findings. Base/head builds pass; strict performance has the same inherited chat-boot request violation (36 > 35). Testbox did not admit within about ten minutes, so proof ran locally with one worker.
Related: openclaw#168887, openclaw#169439, openclaw#169441 ## What Problem This Solves Fixes missing nested chat activity and stale media resources after the Solid transcript migration, restoring 20 failing `checks-ui` cases inherited by unrelated PRs. ## User Impact Expanded activity shows its nested calls again. Parked image and video previews release their resources and reconnect through the existing scope-checked caches. No settings, protocol, storage, or migration changes. ## Why This Change Was Made Keep deferred tool-card children inside their existing Lit-owned range instead of creating nested Solid roots that are retired while parked. Bind image and video resource lifetimes to the existing Solid presentation context. Update lifecycle fixtures to await the documented deferred Solid disposal boundary without removing or weakening any assertions. Checked steipete's open UI PRs before editing. openclaw#169442 overlaps the activity headline, not these repairs. openclaw#169346 has green UI results on an older tree, but its head lacks the later bridge changes and does not repair these current-main failures. No overlap with Pash/Sarah changes. ## Evidence - Baseline `1bb91e30fd5`: all **20 reported failures reproduced** across eight files (116 other cases passed). - Rebased onto current main, including openclaw#169439 and openclaw#169441: **190 tests passed across 10 files**, including all 20 failures plus media handoff and native media siblings. - `pnpm tsgo:ui`: passed. - `pnpm run tsgo:test:ui`: all UI shards passed. - Changed-file oxlint/oxfmt, line-cap ratchet against `origin/main`, and `git diff --check`: passed. - Independent P0–P2 review: no actionable findings. - Original failing CI: [shard 2](https://github.com/openclaw/openclaw/actions/runs/38184982892/job/114605449166), [shard 3](https://github.com/openclaw/openclaw/actions/runs/38184982892/job/114605449173), and [image admission run](https://github.com/openclaw/openclaw/actions/runs/38184424359). ### Expanded activity, before and after Captured from the same Chromium fixture and inspected. Before: the opened parent has no nested calls. After: the calls render and the original height/collapse assertions pass. | Before | After | | --- | --- | |  |  | |  |  | <details> <summary>Per-test disposition: all 20 fixed</summary> | Test file | Previously failing cases | Status | | --- | --- | --- | | `chat-activity-layout.browser.test.ts` | Expanded height and collapse, standalone | fixed | | `chat-activity-layout.browser.test.ts` | Expanded height and collapse, inline | fixed | | `chat-activity-layout.browser.test.ts` | Opened lone step with routine nested calls | fixed | | `chat-activity-disclosure.test.ts` | Settled completed step with routine nested calls | fixed | | `chat-position-rail.test.ts` | Focused previews, pointer exit, removal, and session reset | fixed | | `chat-message-attachment-admission.test.ts` | Stale admission after source replacement/disconnect | fixed | | `chat-message-text-chip-admission.test.ts` | Stale comment observations | fixed | | `chat-message-text-chip-admission.test.ts` | Stale paste observations | fixed | | `chat-transcript-invalidation.test.ts` | Hidden video preview, rendered parent | fixed | | `chat-transcript-invalidation.test.ts` | Hidden video preview, parked parent | fixed | | `chat-message-media-lifecycle.test.ts` | Guarded managed image reconnect | fixed | | `chat-message-image-admission.test.ts` | Loaded assistant image remount | fixed | | `chat-message-image-admission.test.ts` | Loaded assistant image reconnect | fixed | | `chat-message-image-admission.test.ts` | Detached image after authToken change | fixed | | `chat-message-image-admission.test.ts` | Detached image after sessionKey change | fixed | | `chat-message-image-admission.test.ts` | Detached image after agentId change | fixed | | `chat-message-image-admission.test.ts` | Detached image after connectionEpoch change | fixed | | `chat-message-image-admission.test.ts` | Detached image after resourceBasePath change | fixed | | `chat-message-image-admission.test.ts` | Detached image after policyKey change | fixed | | `chat-message-image-admission.test.ts` | Detached image after expiry | fixed | No reported case was already fixed on the captured main baseline. The managed-image remount sibling already passed and continues to pass. </details> Two-way door: reverting restores the prior rendering/resource behavior without changing persistent state. Blast radius is Control UI chat activity disclosure and image/video preview lifecycles. Co-authored-by: Ayaan Zaidi <[email protected]>
What Problem This Solves
Fixes: unsaved input in a Dashboard MCP App disappears when the side panel is minimized and reopened.
User Impact
Loaded apps keep their local state through the panel transition. Existing offscreen teardown, lease expiration, reconnect, and lazy first-load policies remain unchanged. No configuration or migration is required.
Why This Change Was Made
The Solid board port (#168871) let the content renderer see the new active flag before the lifecycle published its new visibility. Reopening briefly looked like an active offscreen app and tore down its iframe. The existing cell snapshot now publishes activity with the observed visibility instead of mixing two revisions. No new state owner or retention exception is introduced.
Evidence
On current main
5889e62f4902b8f3fa4b6eb2cecbbd26f5b8ceb0, the production-bundle E2E run of the three reported files had 1 failure / 17 passes: the board retention case received an empty string instead ofKeep this unsaved dashboard note. All nine history-prepend cases and all four chat-scroll cases already passed; main's84fb3196ed5repairs their history/follow owners, so they are not duplicated here.With this fix, the unchanged complete
board-mcp-app.e2e.test.tspasses 5/5, including retention through split, expanded, minimized, and inactive states; reconnect replacement; renewal; and offscreen lazy loading. The retention case takes 2.797 s, and the full bundled command takes 23.19 s. No tests, expectations, retries, or timeouts changed. A separate original-source capture reproduces the empty-note failure in 18.065 s.Command:
node scripts/run-vitest.mjs run --config test/vitest/vitest.ui-e2e.config.ts --configLoader runner --project ui-e2e-bundled --maxWorkers=1 ui/src/e2e/board-mcp-app.e2e.test.tsFocused checks: all 14 board MCP lifecycle unit cases pass, including active-offscreen teardown, inactive retention, expiry, and reconnect.
pnpm tsgo:ui, scoped oxlint, oxfmt, the line-cap ratchet againstorigin/main, andgit diff --checkpass. Independent Codex review of the final diff is scoped-clean through P2.Before and after reopening
Both screenshots use the same synthetic app. Before, the iframe restarts at its initial scroll position and loses the note. After, it remains at the note with its input intact.
Two-way door: reverting restores the old panel-transition behavior. Blast radius is the board MCP App renderer; no stored data, Gateway behavior, or channel delivery changes.