Skip to content

fix(ui): restore chat disclosure and media lifecycles - #169468

Merged
obviyus merged 1 commit into
mainfrom
fix/ui-checks-main-red
Oct 12, 2026
Merged

obviyus merged 1 commit into
mainfrom
fix/ui-checks-main-red

Conversation

@obviyus

@obviyus obviyus commented Oct 12, 2026 •

Copy link
Copy Markdown
Collaborator

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.

Evidence

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
Expanded activity missing nested calls Expanded activity displaying nested calls
Opened lone step missing nested calls Opened lone step displaying nested calls
Per-test disposition: all 20 fixed
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.

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.

@clawsweeper

clawsweeper Bot commented Oct 12, 2026 •

Copy link
Copy Markdown
Contributor

🦞👀
ClawSweeper picked this up.

Pull request received. I will update this pull request when review starts.

ClawSweeper review complete

ClawSweeper finished reviewing this revision. The review result is being finalized.

View the workflow run.

@clawsweeper clawsweeper Bot added P2 Normal backlog priority with limited blast radius. proof: 📸 screenshot Contributor real behavior proof includes screenshot evidence. rating: 🦐 gold shrimp Decent PR readiness signal, but merge confidence is limited. status: 👀 ready for maintainer look ClawSweeper has no concrete contributor-facing blocker left for this PR. labels Oct 12, 2026
@clawsweeper

clawsweeper Bot commented Oct 12, 2026

Copy link
Copy Markdown
Contributor

Codex review: needs maintainer review before merge.

What this changes

This PR restores nested activity disclosures and releases image and video preview resources when retained chat content is parked.

Example: Expand Batch 1 containing reads of source-0.ts through source-9.ts.

  • Before: The expanded batch shows Tool input but omits its nested reads.
  • After: All ten nested reads appear above Tool input.

Review scores

Measure Result What it means
Overall readiness 🦐 gold shrimp (3/6) A focused, useful repair with inspected disclosure screenshots and no actionable finding; behavioral evidence remains centered on component fixtures and reported test results.
Proof confidence 🦐 gold shrimp (3/6) This collaborator-authored PR is outside the ordinary contributor proof gate; inspected Chromium fixture screenshots show restored nested disclosures, while media cleanup and reconnect behavior have mounted-test support rather than shipped-app evidence.
Patch quality 🐚 platinum hermit (4/6) No actionable review findings were identified.

Product

Kind: Bug fix · Worth it: Yes · Fix scope: Complete
User problem: Expanded chat activity omits nested calls, while parked media previews retain resources that should be released and reacquired on return.
Reason: Collaborator authorship establishes direction, and the focused repair restores the migration's documented behavior.

Regression provenance

Possible regression — suspected (reviewed change). No predecessor PR is attributed.

Merge readiness

✅ Ready for maintainer review

Keep open: this collaborator-authored PR repairs current-main chat rendering regressions with a focused change and no actionable introduced defect found; required CI remains pending.

Priority: P2
Reviewed head: f8b522d075c531330450df80fe4ebd96de55f5db

Before merge

None.

Findings

None.

Tests

  • Missing end-to-end proof: The supplied evidence does not show image/video parking and reacquisition through a running shipped Control UI session.
Agent review details

How this fits together

Control UI transcript rows consume message and presentation state, cross the retained Solid/Lit boundary, and render activity cards and media previews using existing resource owners.

flowchart TD
  A[Transcript state] --> B[Solid chat rows]
  B --> C[Retained Lit content]
  C --> D[Tool card children]
  C --> E[Presentation signal]
  E --> F[Image and video previews]
  F --> G[Existing media resource owners]
Loading

Technical review

Best possible solution:

Keep deferred children within the existing card range and let the established presentation signal control media resource lifetimes.

Do we have a high-confidence way to reproduce the issue?

Pinned main source exposes the missing presentation cleanup, and inspected before/after screenshots demonstrate the disclosure failure; no target code or tests were run during this read-only review.

Is this the best way to solve the issue?

The repair uses the existing rendering and presentation owners, preserves scope-checked caches, and retains behavioral assertions without adding competing state or configuration.

AGENTS.md: found and applied where relevant.

Codex review notes: model internal, reasoning medium; reviewed against 0387f4f96a29.

Provenance checked

  • Nested activity rendering keeps the original intent (4e3818b: Migrate transcript rendering to Solid while preserving disclosure behavior through retained Lit interoperability.)
  • Image and video preview lifecycles keeps the original intent (4e3818b: Preserve media behavior and existing resource ownership during the renderer migration.)
  • Lifecycle fixture settlement keeps the original intent (4e3818b: Exercise mounted Solid behavior while retaining existing lifecycle assertions; the interop owner defers disposal after actual removal.)

Testing

Proof path: in-process harness.

Security

None.

Evidence

What I checked:

PR surface

Source +11, Tests +10. Total +21 across 9 files. Added test files: 0.

View PR surface stats
Area Files Added Removed Net
Source 3 74 63 +11
Tests 6 11 1 +10
Docs 0 0 0 0
Config 0 0 0 0
Generated 0 0 0 0
Other 0 0 0 0
Total 9 85 64 +21

Review metrics

Metric Value Why it matters
Production versus tests Production +74/-63; tests +11/-1 Small production growth adds presentation-bound cleanup while simplifying activity rendering; test changes preserve assertions and await existing disposal boundaries.

Labels

Label changes:

  • add P2: Repairs bounded Control UI disclosure and preview lifecycle regressions without evidence of a core outage or blocked first-use flow.
  • add proof: 📸 screenshot: Contributor real behavior proof includes screenshot evidence.
  • add rating: 🦐 gold shrimp: Overall readiness is 🦐 gold shrimp; proof is 🦐 gold shrimp and patch quality is 🐚 platinum hermit.
  • add status: 👀 ready for maintainer look: ClawSweeper has no concrete contributor-facing blocker left for this PR.

Label justifications:

  • P2: Repairs bounded Control UI disclosure and preview lifecycle regressions without evidence of a core outage or blocked first-use flow.
  • rating: 🦐 gold shrimp: Overall readiness is 🦐 gold shrimp; proof is 🦐 gold shrimp and patch quality is 🐚 platinum hermit.
  • status: 👀 ready for maintainer look: ClawSweeper has no concrete contributor-facing blocker left for this PR.
  • proof: 📸 screenshot: Contributor real behavior proof includes screenshot evidence.

Rank-up moves

Optional improvements that raise the rating; they are not merge blockers.

  • Show image and video preview release and restoration when switching away from and back to a running Control UI conversation.

Rating scale

6/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.

Workflow

ClawSweeper edits this one comment on every review. Comment @clawsweeper re-review for a fresh review only. Repair and merge execution lanes are retired.

Reviewed October 11, 2026, 8:14 PM ET / October 12, 2026, 00:14 UTC.

@obviyus

obviyus commented Oct 12, 2026

Copy link
Copy Markdown
Collaborator Author

Maintainer override (Ayaan approved landing): the only red job on this head (f8b522d) is checks-ui (1/3), which is inherited from main, not caused by this diff.

  • All 572 UI test files pass in that shard. Vitest fails the shard only for 2 unhandled errors in src/pages/chat/components/chat-message.mcp-app.test.ts: "This ChildPart has no parentNode…", a Lit part being updated after its container was removed during the Solid migration.
  • The same unhandled error appears on steipete's build(ui): upgrade Solid to 2.0.0-rc.14 #169247 (head 181af1d, checks-ui job 114603855379), which shares no files with this PR.
  • This PR fixes the 20 other checks-ui failures on main (activity disclosure/layout, position rail, media/attachment/text-chip admission, transcript invalidation). 190 targeted tests pass, and ClawSweeper is ready on this exact head.

@obviyus
obviyus merged commit 4cbe7e6 into main Oct 12, 2026
99 of 105 checks passed
@obviyus
obviyus deleted the fix/ui-checks-main-red branch October 12, 2026 00:20
github-actions Bot pushed a commit to Desicool/openclaw that referenced this pull request Oct 12, 2026
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 |
| --- | --- |
| ![Expanded activity missing nested calls](https://github.com/user-attachments/assets/28225f6e-0c93-4bc6-a2bc-6a6467f4e138) | ![Expanded activity displaying nested calls](https://github.com/user-attachments/assets/81afcf4b-f661-4e61-a923-c6fbfed2ad58) |
| ![Opened lone step missing nested calls](https://github.com/user-attachments/assets/8858d53c-456e-4f6f-91e2-326a0a586a61) | ![Opened lone step displaying nested calls](https://github.com/user-attachments/assets/d12fce94-8055-4483-bf4a-db81ef527a03) |

<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]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

app: web-ui App: web-ui P2 Normal backlog priority with limited blast radius. proof: 📸 screenshot Contributor real behavior proof includes screenshot evidence. rating: 🦐 gold shrimp Decent PR readiness signal, but merge confidence is limited. size: S status: 👀 ready for maintainer look ClawSweeper has no concrete contributor-facing blocker left for this PR.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant