Skip to content

fix(ui): preserve proof recordings during screenshots - #138459

Merged
steipete merged 3 commits into
mainfrom
steipete/distracted-hofstadter-a30ba0
Sep 4, 2026
Merged

steipete merged 3 commits into
mainfrom
steipete/distracted-hofstadter-a30ba0

Conversation

@steipete

@steipete steipete commented Sep 4, 2026 •

Copy link
Copy Markdown
Contributor

What Problem This Solves

Resolves a problem where Control UI proof recordings could turn into a small row or a resized page padded with gray whenever a still screenshot was captured during recording. The WebM retained its expected dimensions, so dimension-only checks missed the damaged content.

The investigation also exposed an initial Logs load being repeatedly cancelled by ordinary Gateway metadata snapshots. That prevented the unchanged auto-follow proof from reaching its first screenshot.

Why This Change Was Made

Recorded proof now uses the existing unclipped viewport capture owner. Element-only PNGs are cropped afterward in Node with the already-installed image library; tall forms retain their meaningful viewport. The migration follows the recording/capture gates across the complete Control UI proof neighborhood rather than repairing only the reported callers. Fonts, meaningful content, finite presentation-owner motion, real interactions, and functional assertions remain part of readiness. Nonrecording native captures and ordinary safe viewport captures retain their existing paths.

The Logs repair moves automatic loading into the existing connection/identity lifecycle hook and deletes its row-emptiness initializer. Ordinary snapshots no longer supersede a pending tail or reload a successfully empty log. Completion-triggered scrolling is fenced to the request's connection epoch, so a retired request cannot force-scroll the replacement connection; reconnects, explicit refresh, incremental polling, and stale-response rejection retain their owners. No new flags, configuration, schema, dependencies, Playwright monkey-patches, or frame filtering are introduced. Gateway command-authority and timeout fixtures are outside this change.

User Impact

Developers and reviewers can retain element screenshots without damaging the accompanying recording. The Logs page also stops needlessly restarting its initial request on metadata updates. No setup or migration is required.

This does not claim to fix Chromium's native startup or viewport-resize padding: a no-screenshot control reproduced that separate behavior. Those frames remain intact and are explicitly distinguished from screenshot-induced corruption. Raw real-Gateway footage stays local because it can contain host/profile labels; the attached evidence is synthetic-only and was visually inspected.

Evidence

  • Reproduced before editing on Playwright 1.62.1 and full Chrome for Testing 151.0.7922.34, not headless shell. Finalized video pixels failed for a 302×29 locator, a page clip, and a full-page screenshot on a tall document; the plain viewport control stayed intact.
  • Direct upstream source confirms the shared-surface mechanism: Chromium CaptureScreenshot changes the view size before restoring it, while OnFrameFromVideoConsumer observes that surface. Installed Playwright source confirms the clip and gray-padding path.
  • The encoded-pixel regression fails with the old capture path and passes with viewport capture plus PNG crop. It checks finalized WebM content and crop pixels, not just dimensions. Font, fractional-bound/DPR, scrolling, containment, lazy-content, and finite-owner-motion regressions also pass.
  • 289 distinct capture scenarios passed in the original sweep; the previously blocked Logs auto-follow scenario now also passes its unchanged 200-row, cursor-200, 201-row, and scroll assertions. The four real-Gateway cron scenarios passed with recording enabled.
  • The initial-load and stale-scroll regressions fail against their unfixed owners. The final owner/sibling suite passed 36 cases, and three browser scenarios passed. The real-Gateway lifecycle's first cold attempt exceeded its existing timeout; the diagnostic and byte-identical final run passed without changing that timeout.
  • Finalized recordings were decoded to RGB pixels and synthetic captures inspected. The earlier static-scene recording independently passed all 43 encoded frames; no bad frames were filtered. Responsive/native-padding limitations remain reported rather than silently removed.
  • Scoped formatting, type-aware lint, UI/core-test types, repository guards, and unchanged-assertion checks passed. Fresh isolated Codex review of the complete final diff was scoped-clean at the repository's blocking threshold; the rebased candidate also received fresh review.

After rebasing onto 9f1c8a1c58bd1e889df4f7e78742ade56d7efefe, 189 browser cases across 27 files and 36 Logs owner/sibling cases passed with the original capture/recording gates enabled. This selection covers every caller file overlapping main, the screenshot pixel/font/readiness owner, Logs, and the original pin/sidebar/tool-turn captures. Four rebase conflicts preserve current-main Canvas, Workboard, and panel assertions. These are overlapping reruns, not additional distinct cases to add to the earlier 289. The unchanged earlier real-Gateway cron/lifecycle proof is retained rather than presented as a fresh run. A fresh isolated Codex review of the full rebased candidate was scoped-clean at P0.

All 430 frames of five selected post-rebase recordings were decoded. Logs, dashboard pinning, background tasks, and the synthetic owner had no padding flags. Nine Workboard modal frames triggered the gray-edge heuristic; visual inspection confirmed the intact rendered modal/backdrop. The raw nonzero detector result is retained, with no frames removed.

Production LOC remains +14 / −19 (net −5). The final rebased candidate has 119 files, with tests/support +2,551 / −1,171 (net +1,380). The earlier 119-file published migration had tests/support +2,479/−1,157; the interim 05dc7d725ecc108a4a371f8c66444e45f9c380b2 candidate had 120 files and tests/support +2,626/−1,234. Those historical scopes are preserved rather than added together. The only product runtime change remains the smaller Logs lifecycle owner.

The first post-rebase changed gate stopped at core-test types because the private checkout still had @openclaw/fs-safe 0.7.0 installed while the pinned lockfile requires 0.7.2. pnpm install --frozen-lockfile restored the declared version with no tracked dependency changes, and the full core-test typecheck retry passed. UI types, coercion/dead-export guards, and the complete 118-file lint/style scope then passed; this was local installation drift, not a source repair.

CI follow-up: run 33903611044 found one shared capture-gate unit regression in both the UI and Node shards. The helper now resolves default locators only inside enabled recording capture, and the existing nonrecording fixture explicitly models Page.video() === null. Disabled capture still accesses neither the page nor the artifact owner. The failure reproduces locally before repair; afterward 13 unit/retention cases and 26 real-browser caller scenarios pass. All 641 frames in eight new recordings decode with zero padding flags. Scoped changed checks and fresh isolated Codex review cover this two-file test-support follow-up; the Logs production repair is unchanged.

The same CI run also exceeded the unchanged startup JavaScript budget (350,364 B against 350,141 B). That prerequisite is now resolved by landed #138490, merge 7ab8ca3a6b6e, which credits Ayaan Zaidi (@obviyus) and the equivalent work/proof in superseded #138461 and #138472. This PR does not duplicate that repair or change a startup budget. Historically, exact-head CI for d3f29db68002407ef0cac102d8be6d3b49d3b0ec completed with 89 successful jobs, the startup-performance failure (350,400 B against 350,141 B), and the resulting aggregate failure; both previously failing test shards passed. Those historical results remain evidence for that revision, not a current blocker description.

The retained resume proof for published 14845ee275ad435a0ad481075ab705c4b931272b measured 346,223 B gzip, below the original 350,141 B ceiling, with 49 owner/gate cases, 48 browser cases across six files, and 199 decoded frames with no padding flags. These overlap earlier proofs and are not additive distinct totals. No startup budget is changed here.

Focused final Logs proof commands:

node scripts/run-vitest.mjs ui/src/pages/logs/logs-page.test.ts ui/src/pages/logs/view.test.ts ui/src/pages/logs/data.test.ts ui/src/lit/gateway-page-controller.test.ts ui/src/lit/poll-controller.test.ts
OPENCLAW_CAPTURE_UI_PROOF=1 OPENCLAW_UI_E2E_ARTIFACT_DIR=.artifacts/capture-land/logs/epoch-after node scripts/run-vitest.mjs run --config test/vitest/vitest.ui-e2e.config.ts --configLoader runner ui/src/e2e/logs-autofollow.e2e.test.ts

Final CI repairs and upstream integration

CI 33914894907 exposed two test-lifecycle defects on 14845ee275ad435a0ad481075ab705c4b931272b. Both were independently investigated and published in interim commit 05dc7d725ecc108a4a371f8c66444e45f9c380b2 (+148/−78 test/support across three files). The final branch is rebased onto 05a236c7afbcf1956e40642d4f1777af4a378da3; the first two capture commits remain patch-identical. Its final commit 8d74a25c38e3d3a346a0b88f14938a22616f96f6 retains only the two-file geometry fix (+73/−15, no product runtime changes). The duplicate Settings delta is removed because main already contains the canonical repair.

  • Capture readiness: the image had no own animation while its chat-bubble ancestor still translated/faded. The shared helper now waits for finite animations through presentation ancestors and shadow hosts before taking the same unclipped viewport PNG. Strict before/after geometry, viewport containment, fractional/device-pixel cropping, fonts/content gates and original image-byte continuity assertions remain. Against the original helper, deterministic regressions captured parent opacity 0.995161 and a shadow-host entrance still running; both fail before the fix and pass after it. The same infinite child remains running without cancellation or finish events. These two files are byte-identical to their proven 05dc7d… versions.
  • Settings document ownership: the final settings-layout.e2e.test.ts is byte-identical to pinned main, retaining landed #138482, merge 3dd2b404c37ddd028d6994b31ee82684c9400efd. It keeps all three cold-boot pages alive through final assertions, preserves aggregate late-startup provider-copy exclusion and rich HTTP/request-failure provenance, and uses fixture-owned failure capture. Our independently proven cold-context/UI-journey alternative from 05dc7d… is no longer in the final source. No error-code filters, timeouts, retries, or duplicate coverage were added.

Upstream #138482 independently reproduced the same test-owned hard-navigation cancellation on Linux Chromium 144: 298 passed / 1 natural failure before; 299/299 after; focused Settings 6/6. HTTP 503 and connection-reset negative controls still fail with diagnostics; its exact-head CI 33913547937 passed. This is retained upstream proof, not a new Linux run for this branch.

Our independent forensic evidence is also retained: New's composer was ready at 650 ms; hard Chat navigation began at 665 ms. Outgoing scripts received HTTP 200 and were fulfilled at 681/729 ms, then Chromium canceled them with net::ERR_ABORTED around the 760 ms Chat commit. The removed alternative passed 308 tests across 64 files in 33917106725, and seven local Settings cases. Real script-reset negative controls still failed both cold cases as intended. Those results support the diagnosis; they are not claimed as tests of the final Settings implementation.

Fresh proof on the final rebased source passed 49 owner/gate cases and 15 browser cases across five files, including the entire unchanged six-case Settings file, original image handoff, capture ancestor/shadow-host/font/DPR/containment and exact crop pixels, and Logs auto-follow/layout. The synthetic recording retains all 174 decoded samples, with no corrupt samples. All 40 stills and seven complete video timelines were visually inspected. These focused reruns overlap historical proof and are not additive distinct-case totals. The normal scoped changed gate passed with the two geometry files plus the preserved Settings conflict surface: core-test/UI types, local oxfmt, type-aware lint/style and repository guards; git diff --check passed. Fresh isolated full-branch review against pinned base 05a236c7afbcf1956e40642d4f1777af4a378da3 was scoped-clean at P0, findings[], with source verification, secret scanning, and reviewer isolation retained.

ClawSweeper follow-through: the actual conflict was resolved by preserving upstream Settings exactly; current-main refresh and the existing recording/Logs coverage are complete. The existing Photon crop/decode/free contracts were inspected directly and exercised through exact crop/finalized-recording tests. The complete candidate has no new configuration/default, schema or stored-data surface, so the bot's truncated-file compatibility prompts do not apply. Native current-main baseline dbc554b was refreshed and inspected. The relevant Settings, Logs and screenshot-owner source matches the pinned rebase baseline; Settings retains the upstream repair, while main still has the old Logs snapshot initializer and surface-only capture readiness. Required exact-head CI for 8d74a25c38e3d3a346a0b88f14938a22616f96f6: CI run33922243194 is attached via pull_request to the full head SHA; observed queued, final result pending. The parent owns CI watch and the exact-head checkpoint; preparation and merge have not run. Startup prerequisite #138490 remains landed, with the earlier 346,223 B measurement below the original 350,141 B ceiling; this PR changes no budget.

Combined proof commands:

node scripts/run-vitest.mjs ui/src/pages/logs/logs-page.test.ts ui/src/pages/logs/view.test.ts ui/src/pages/logs/data.test.ts ui/src/lit/gateway-page-controller.test.ts ui/src/lit/poll-controller.test.ts ui/src/test-helpers/control-ui-e2e.test.ts ui/src/test-helpers/control-ui-e2e-artifacts.node.test.ts
OPENCLAW_CAPTURE_UI_PROOF=1 OPENCLAW_UI_E2E_RECORD=1 node scripts/run-vitest.mjs run --config test/vitest/vitest.ui-e2e.config.ts --configLoader runner ui/src/e2e/chat-flow.image-handoff.e2e.test.ts ui/src/e2e/initial-connect-splash.e2e.test.ts ui/src/e2e/settings-layout.e2e.test.ts ui/src/e2e/logs-autofollow.e2e.test.ts ui/src/e2e/logs-layout.e2e.test.ts -t 'submitted image|recovery pixels|finalized recording pixels|font pixels|fractional bounds|Control UI settings layout mocked Gateway E2E|returns to the newest line|keeps wrapped filters'
node scripts/check-changed.mjs --base 05a236c7afbcf1956e40642d4f1777af4a378da3 -- ui/src/e2e/initial-connect-splash.e2e.test.ts ui/src/test-helpers/control-ui-e2e-screenshot.ts ui/src/e2e/settings-layout.e2e.test.ts

Screenshot-induced corruption: before / after

Before: finalized recording frame during a locator screenshot.

Before: a row-only recording frame padded gray

After: finalized frame while retaining the same element through a viewport capture and off-browser crop.

After: all four synthetic viewport quadrants remain intact

Logs proof blocker: before / after

The synthetic call-ordered fixture exposed cancellation of the first request as one row instead of 200. This is not a claim that a real cursorless Gateway request normally returns only an incremental line.

Before: repeated initial request leaves only the fixture's line 201

After: the original initial tail is retained through line 200

@clawsweeper

clawsweeper Bot commented Sep 4, 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.

@steipete
steipete marked this pull request as ready for review September 4, 2026 18:00
@openclaw-barnacle openclaw-barnacle Bot added app: web-ui App: web-ui size: XL maintainer Maintainer-authored PR labels Sep 4, 2026
@steipete

steipete commented Sep 4, 2026

Copy link
Copy Markdown
Contributor Author

The shared capture-gate failure from CI run 33903611044 is repaired. Both failing test shards hit the same stale screenshot-only fixture and eager default locator. Disabled capture now remains inert; the nonrecording fixture models Playwright's video() === null contract.

The original failure reproduces locally. The repair passes 13 unit/retention cases, 26 Chromium caller scenarios, the scoped changed checks, and isolated Codex review. Eight finalized recordings contain 641 decoded frames with zero padding flags. No assertions, timeouts, recording gates, or production Logs behavior were weakened or changed.

The independent startup-size failure is tracked by existing PR #138461. The budget remains unchanged. CI on the updated head and native preparation still need to pass before landing.

@steipete

steipete commented Sep 4, 2026 •

Copy link
Copy Markdown
Contributor Author

LAND-READY — exact head 8d74a25c38e3d3a346a0b88f14938a22616f96f6. Parent exact-head checkpoint approved; independent live verification confirms CI 33922243194, attempt 1 completed SUCCESS (updated 2026-09-04T21:52:28Z), with required openclaw/ci-gate SUCCESS. GitHub reports the PR mergeable; no enforced review approval is required by the inspected rules.

OPENCLAW_TESTBOX=1 scripts/pr prepare-run 138459 completed successfully. Native hosted gates passed (hosted_exact_or_recent_parent); HOSTED_GATES_TARGET_HEAD_SHA, local prep head and verified remote PR head all equal the exact SHA above. The branch was already at the prepared head, so no push or head change occurred. No changelog or budget change was required.

The latest ClawSweeper review, published at 21:54 UTC for this exact head, reports no introduced correctness or security findings. Its remaining CI action and the earlier current-main refresh/recording/Logs rank-up moves are resolved. The complete 119-file inventory is Control UI code/tests/support: runtime +14/−19 (net−5), tests/support +2551/−1171. There are no configuration/default, schema, persistent-data migration, API or dependency changes. The generic config/data prompts marked unknown-truncated-pull-files are therefore not applicable; no migration-test claim is being substituted. Existing Photon crop/decode/free contracts were directly inspected and exercised. Fresh isolated full-branch review at pinned base 05a236c7afbcf1956e40642d4f1777af4a378da3 is scoped-clean at P0, findings[].

Final-source local proof passes 49 owner/gate and 15 browser cases, including all six unchanged upstream Settings cases. All 174 decoded recording samples are intact; 40 stills and seven complete sampled video timelines were inspected. Exact commands/results:

node scripts/run-vitest.mjs ui/src/pages/logs/logs-page.test.ts ui/src/pages/logs/view.test.ts ui/src/pages/logs/data.test.ts ui/src/lit/gateway-page-controller.test.ts ui/src/lit/poll-controller.test.ts ui/src/test-helpers/control-ui-e2e.test.ts ui/src/test-helpers/control-ui-e2e-artifacts.node.test.ts
# 49 passed /7 files

OPENCLAW_CAPTURE_UI_PROOF=1 OPENCLAW_UI_E2E_RECORD=1 OPENCLAW_UI_E2E_ARTIFACT_DIR=/tmp/objective-galileo-pr138459-rebased node scripts/run-vitest.mjs run --config test/vitest/vitest.ui-e2e.config.ts --configLoader runner ui/src/e2e/chat-flow.image-handoff.e2e.test.ts ui/src/e2e/initial-connect-splash.e2e.test.ts ui/src/e2e/settings-layout.e2e.test.ts ui/src/e2e/logs-autofollow.e2e.test.ts ui/src/e2e/logs-layout.e2e.test.ts -t 'submitted image|recovery pixels|finalized recording pixels|font pixels|fractional bounds|Control UI settings layout mocked Gateway E2E|returns to the newest line|keeps wrapped filters'
# 15 passed /5 files; all six upstream Settings cases;174 decoded samples intact

node scripts/check-changed.mjs --base 05a236c7afbcf1956e40642d4f1777af4a378da3 -- ui/src/e2e/initial-connect-splash.e2e.test.ts ui/src/test-helpers/control-ui-e2e-screenshot.ts ui/src/e2e/settings-layout.e2e.test.ts
# exit0; core-test/UI types, local oxfmt, repository guards, type-aware lint/style; no skip flags or root declaration build

git diff --check
# pass

Synthetic before/after proof remains available: recording before, recording after, Logs before, Logs after. Historical counts overlap. Earlier real-Gateway proof is retained for unchanged owners, not claimed as a fresh run; raw host/profile footage remains local. Native Chromium startup/resize padding is a separate observed limitation, with no frames filtered. The independent Settings wrapper lost an auxiliary tarball; its primary log/CDP trace remains intact as a separate follow-up.

Startup #138490 and canonical Settings #138482 remain landed; Settings is byte-identical to pinned main, and the redundant 05dc alternative is removed. Original credit and SHA-distinguished evidence are preserved below and in the PR body. The native merge wrapper will now perform its final exact-head/rules checks; no bypass, admin merge or policy override is requested.


The actual Settings conflict is resolved in rebased head 8d74a25c38e3d3a346a0b88f14938a22616f96f6, based on 05a236c7afbcf1956e40642d4f1777af4a378da3. The first two capture commits are patch-identical. The final CI commit retains only the two-file ancestor/shadow-host readiness fix (+73/−15 test/support).

The Settings alternative published in 05dc7d725ecc108a4a371f8c66444e45f9c380b2 is now absorbed from landed #138482: the final Settings file is byte-identical to pinned main, keeping its three cold-boot pages, aggregate late-startup exclusion, rich HTTP/request-failure provenance and suite-owned diagnostics. Our independent Linux investigation remains historical evidence, not a duplicate final implementation. Upstream Linux before/after and HTTP503/reset controls are retained in that PR, along with its successful CI 33913547937.

Fresh final-source proof passes 49 owner/gate tests and 15 browser cases, including all six upstream Settings cases, original image handoff, capture pixel/ancestor/font/DPR/recording checks and Logs auto-follow/layout. All 174 decoded owner samples are intact; 40 stills and seven complete sampled video timelines were inspected. The normal scoped changed gate passed with the two geometry files plus the preserved Settings conflict surface: core-test/UI types, local oxfmt, type-aware lint/style and repository guards; git diff --check passed. Fresh full 119-file isolated review against the pinned base is scoped-clean at P0, findings[]. Native current-main baseline dbc554b was refreshed and inspected. The relevant Settings, Logs and screenshot-owner source matches the pinned rebase baseline; Settings retains the upstream repair, while main still has the old Logs snapshot initializer and surface-only capture readiness. Required exact-head CI: CI run33922243194 is attached via pull_request to the full head SHA; observed queued, final result pending. Preparation and merge have not run; the parent owns CI watch and the exact-head checkpoint.

Startup prerequisite #138490 remains landed, with credit to @obviyus and superseded #138461/#138472. Published 14845's retained 346,223 B gzip measurement was below the original 350,141 B ceiling. No budget changed. Counts overlap prior proof and are not additive.

Historical checkpoint for d3f29db (superseded status, proof retained)

Landing is blocked on the shared startup-size repair. Exact-head CI for d3f29db68002407ef0cac102d8be6d3b49d3b0ec completed with 89 successful jobs and a performance failure; the required aggregate gate consequently failed. Startup JavaScript measured 350,400 B against the unchanged 350,141 B limit. Existing PR #138461 remains open and owns that repair.

The capture-gate regression is resolved in hosted CI: UI shard 3/3 and Node compact-large-5 both passed on this exact head. Local owner/caller proof, finalized-recording pixel proof, scoped checks, and isolated review are recorded above. Native review artifacts validate for this head.

Native preparation and merge have not run. Resume after the existing performance repair lands and this PR receives green CI covering it; preserve the budget and current proof gates.

@clawsweeper

clawsweeper Bot commented Sep 4, 2026 •

Copy link
Copy Markdown
Contributor

Codex review: blocked before merge. Reviewed September 4, 2026, 5:54 PM ET / 21:54 UTC.

ClawSweeper review

What this changes

The branch captures Control UI screenshots from an unchanged viewport and crops the completed PNG off-browser, while moving Logs automatic initial loads into the shared Gateway lifecycle controller.

Merge readiness

⛔ Blocked before merge - 4 items remain

The branch has coherent owner-bound fixes for recording-safe Control UI proof capture and Logs initial loading; no introduced correctness or security defect was found. It is not land-ready until the remaining exact-head checks complete successfully.

Priority: P2
Reviewed head: 8d74a25c38e3d3a346a0b88f14938a22616f96f6

Review scores

Measure Result What it means
Overall readiness 🐚 platinum hermit (4/6) The implementation and focused coverage are coherent, with required exact-head CI still pending before landing.
Proof confidence 🌊 off-meta tidepool Not applicable: The maintainer-associated PR is not subject to the external-contributor proof gate; its supplied browser-proof narrative is consistent with the reviewed capture and Logs owners.
Patch quality 🐚 platinum hermit (4/6) No actionable review findings were identified.

Verification

Check Result Evidence
Real behavior Not applicable Not applicable: The maintainer-associated PR is not subject to the external-contributor proof gate; its supplied browser-proof narrative is consistent with the reviewed capture and Logs owners.
Evidence reviewed 8 items Recording-safe screenshot owner: The helper captures a full current viewport through CDP, then crops the completed PNG in memory; it does not invoke a browser-side clipped screenshot that could replace recording frames.
Crop and presentation invariants: The helper waits for fonts and finite ancestor/shadow-host animations, verifies viewport containment, rechecks bounds after capture, and encloses fractional bounds when cropping.
Logs lifecycle owner: Logs now delegates automatic initial/reset loading to the Gateway page controller and only synchronizes polling on ordinary snapshots, avoiding metadata-clone reloads of an empty log.
Findings None None.
Security None None.

How this fits together

Control UI end-to-end scenarios create screenshot and recording proof, while the Logs page turns Gateway lifecycle snapshots into initial loads, polling, and scrolling. This change preserves both proof artifacts and lifecycle-correct Logs updates.

flowchart LR
A[Control UI scenario] --> B[Browser recording]
B --> C[Proof capture helper]
C --> D[PNG and video artifacts]
E[Gateway lifecycle snapshot] --> F[Logs page controller]
F --> G[Initial load and polling]
G --> H[Logs display]
Loading

Before merge

  • Resolve merge risk (P1) - The remaining exact-head required checks are still in progress, so full integration coverage has not yet been confirmed for this head.
  • Complete next step (P2) - Wait for the remaining exact-head CI checks to complete successfully.
  • Review config compatibility - Confirm compatibility and upgrade impact for the changed config or default surface before merge.
  • Add data-model compatibility proof - Confirm migration or upgrade compatibility proof before merge.
Agent review details

Security

None.

PR surface

PR surface statistics unavailable: the file list is incomplete.

Review metrics

Metric Value Why it matters
Production vs test/support delta production +14/-19 (net -5); tests/support +2,551/-1,171 (net +1,380) The only runtime change is net-negative in the Logs lifecycle owner; most scope is regression coverage and proof-test support.

Stored data model

Persistent data-model change detected: unknown-truncated-pull-files. Confirm migration or upgrade compatibility proof before merge.

Merge-risk options

Maintainer options:

  1. Decide the mitigation before merge
    Keep the recording-safe capture and lifecycle-owner changes, then land after the exact-head required checks succeed.
  2. Pause or close
    Do not merge this PR until maintainers decide whether the risk is worth taking.

Technical review

Best possible solution:

Keep the recording-safe capture and lifecycle-owner changes, then land after the exact-head required checks succeed.

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

Yes from source inspection: the changed screenshot and Logs lifecycle paths have focused regression coverage, although this read-only review did not execute the browser scenarios.

Is this the best way to solve the issue?

Yes: viewport capture followed by off-browser cropping preserves recordings, and the shared lifecycle controller is the correct owner for automatic Logs initialization.

AGENTS.md: found and applied where relevant.

Codex review notes: model internal, reasoning high; reviewed against 11a46fa85b47.

Labels

Label justifications:

  • P2: This is a bounded Control UI reliability repair without evidence of an urgent user-facing outage.
  • rating: 🐚 platinum hermit: Overall readiness is 🐚 platinum hermit; proof is 🌊 off-meta tidepool and patch quality is 🐚 platinum hermit.
  • status: 👀 ready for maintainer look: ClawSweeper has no concrete contributor-facing blocker left for this PR. Not applicable: The maintainer-associated PR is not subject to the external-contributor proof gate; its supplied browser-proof narrative is consistent with the reviewed capture and Logs owners.

Evidence

What I checked:

  • Recording-safe screenshot owner: The helper captures a full current viewport through CDP, then crops the completed PNG in memory; it does not invoke a browser-side clipped screenshot that could replace recording frames. (ui/src/test-helpers/control-ui-e2e-screenshot.ts:56, 8d74a25c38e3)
  • Crop and presentation invariants: The helper waits for fonts and finite ancestor/shadow-host animations, verifies viewport containment, rechecks bounds after capture, and encloses fractional bounds when cropping. (ui/src/test-helpers/control-ui-e2e-screenshot.ts:72, 8d74a25c38e3)
  • Logs lifecycle owner: Logs now delegates automatic initial/reset loading to the Gateway page controller and only synchronizes polling on ordinary snapshots, avoiding metadata-clone reloads of an empty log. (ui/src/pages/logs/logs-page.ts:132, 8d74a25c38e3)
  • Shared lifecycle caller: The controller invokes initial loading only for initial binding, identity change, or connection transition, while separately invalidating changed lifecycle sources. (ui/src/lit/gateway-page-controller.ts:168, 8d74a25c38e3)
  • Prior Logs history: Earlier merged Logs-tail work identifies Peter Steinberger as a recent contributor to the same owner surface. (ui/src/pages/logs/logs-page.ts, 148229b6dd21)
  • Diff hygiene and scope: The introduced diff passes whitespace validation; its sole production file is net-negative, with the broader change concentrated in Control UI E2E proof tests and support. (8d74a25c38e3)

Likely related people:

  • steipete: Suggested for follow-up; no historical authorship or introduction is verified. (role: unverified routing candidate; confidence: low)

Rank-up moves

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

  • Wait for the remaining exact-head required checks to complete successfully.

Rating scale

Score Internal tier Crab rank Meaning
6/6 S 🦀 challenger crab Exceptional readiness
5/6 A 🦞 diamond lobster Very strong readiness
4/6 B 🐚 platinum hermit Good normal PR; ordinary maintainer review
3/6 C 🦐 gold shrimp Useful, but confidence is limited
2/6 D 🦪 silver shellfish Proof or implementation needs work
1/6 F 🧂 unranked krab Not merge-ready
N/A NA 🌊 off-meta tidepool Rating does not apply

Overall follows the weaker of proof and patch quality.
Shiny media proof means a screenshot, video, or linked artifact directly shows the changed behavior. Runtime, network, CSP, and security claims still need visible diagnostics.

Workflow

  • ClawSweeper keeps one durable marker-backed review comment per issue or PR.
  • Re-runs edit this comment so the latest verdict, findings, and automation markers stay together instead of adding duplicate bot comments.
  • A fresh review can be triggered by eligible @clawsweeper re-review comments, exact-item GitHub events, scheduled/background review runs, or manual workflow dispatch.
  • PR/issue authors and users with repository write access can comment @clawsweeper re-review or @clawsweeper re-run on an open PR or issue to request a fresh review only.
  • Maintainers can also comment @clawsweeper review to request a fresh review only.
  • Fresh-review commands do not start repair, autofix, rebase, CI repair, or automerge.
  • Maintainer-only repair and merge flows require explicit commands such as @clawsweeper autofix, @clawsweeper automerge, @clawsweeper fix ci, or @clawsweeper address review.
  • Maintainers can comment @clawsweeper explain to ask for more context, or @clawsweeper stop to stop active automation.

History

Review history (2 earlier review cycles)
  • reviewed 2026-09-04T18:44:26.773Z sha d3f29db :: blocked before merge. :: none
  • reviewed 2026-09-04T20:43:23.285Z sha 14845ee :: blocked before merge. :: none

@steipete
steipete force-pushed the steipete/distracted-hofstadter-a30ba0 branch from d3f29db to 14845ee Compare September 4, 2026 20:10
@clawsweeper clawsweeper Bot added P2 Normal backlog priority with limited blast radius. rating: 🐚 platinum hermit Good normal PR readiness with ordinary maintainer review expected. status: 👀 ready for maintainer look ClawSweeper has no concrete contributor-facing blocker left for this PR. labels Sep 4, 2026
Capture recording-safe viewport pixels and crop element PNGs outside the browser while preserving capture gates, readiness, and functional assertions.

Move initial Logs reads to the connection lifecycle and fence delayed scroll completion to the request epoch. Retain negative controls, finalized recording-pixel proof, 289 capture scenarios, and focused Logs owner/browser evidence in the PR.
Resolve viewport locators only in the enabled recording branch and model
Page.video() in the existing non-recording capture fixture. Retain the
disabled-gate and owner-directory assertions, including no Page access
before capture is enabled.

The failing CI test reproduces locally before this change. Afterward,
13 unit/retention cases and 26 browser caller scenarios pass; all 641
frames in eight finalized recordings decode without padding flags.
Wait for finite ancestor and shadow-host motion before proof capture while
retaining strict geometry, image-byte continuity and recording pixels.
Extend the existing browser fixtures to prove readiness without stopping
perpetual descendant animation.

The duplicate Settings CI repair was absorbed from main via #138482;
retain its cold-document coverage and failure diagnostics unchanged.
@steipete
steipete force-pushed the steipete/distracted-hofstadter-a30ba0 branch from 05dc7d7 to 8d74a25 Compare September 4, 2026 21:41
@steipete
steipete merged commit 08324bb into main Sep 4, 2026
132 checks passed
@steipete
steipete deleted the steipete/distracted-hofstadter-a30ba0 branch September 4, 2026 22:00
@steipete

steipete commented Sep 4, 2026

Copy link
Copy Markdown
Contributor Author

Merged via squash.

github-actions Bot pushed a commit to Desicool/openclaw that referenced this pull request Sep 5, 2026
* fix(ui): preserve proof recordings during screenshots

Capture recording-safe viewport pixels and crop element PNGs outside the browser while preserving capture gates, readiness, and functional assertions.

Move initial Logs reads to the connection lifecycle and fence delayed scroll completion to the request epoch. Retain negative controls, finalized recording-pixel proof, 289 capture scenarios, and focused Logs owner/browser evidence in the PR.

* test(ui): keep disabled proof capture inert

Resolve viewport locators only in the enabled recording branch and model
Page.video() in the existing non-recording capture fixture. Retain the
disabled-gate and owner-directory assertions, including no Page access
before capture is enabled.

The failing CI test reproduces locally before this change. Afterward,
13 unit/retention cases and 26 browser caller scenarios pass; all 641
frames in eight finalized recordings decode without padding flags.

* test(ui): wait for proof presentation ancestors

Wait for finite ancestor and shadow-host motion before proof capture while
retaining strict geometry, image-byte continuity and recording pixels.
Extend the existing browser fixtures to prove readiness without stopping
perpetual descendant animation.

The duplicate Settings CI repair was absorbed from main via openclaw#138482;
retain its cold-document coverage and failure diagnostics unchanged.
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 maintainer Maintainer-authored PR P2 Normal backlog priority with limited blast radius. rating: 🐚 platinum hermit Good normal PR readiness with ordinary maintainer review expected. size: XL 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