Skip to content

fix(ui): show video compression errors and honest preparation progress - #198225

Open
roboclaw-bot wants to merge 3 commits into
mainfrom
openclaw/webchat-mobile-video-compression
Open

roboclaw-bot wants to merge 3 commits into
mainfrom
openclaw/webchat-mobile-video-compression

Conversation

@roboclaw-bot

@roboclaw-bot roboclaw-bot commented Nov 13, 2026 •

Copy link
Copy Markdown
Collaborator

Related: #194249 (closed report; no closing-fix evidence was available).

What Problem This Solves

In Chrome, including the reported mobile case, failed video compression shows a generic retry action without an inline cause, and post-encoding attachment reads can appear to restart compression progress.

User Impact

The existing tile shows an actionable, sanitized failure reason and bounded stage/error code. Encoding and attachment preparation have distinct progress labels, and failed tiles can wrap recovery text without clipping the controls. Original-file retry, cancellation, queued work, staged-file ordering, and negotiated batch admission remain owned by the existing lifecycle.

Open for review, not ready to merge: real mobile rendering, inspected before/after screenshots, and hardware WebCodecs behavior remain unqualified. The reported encoding failure remains unreproduced and unroot-caused; a smaller successful resend is not proof that it works. This website change is not deployed and is not part of an Android APK.

Why This Change Was Made

Keep failure and phase state with the current worker wrapper, reader/controller, and tile rather than introducing another upload path. Diagnostics contain only fixed stage/category values, never codec exceptions, URLs, filenames, or recording contents. Codec negotiation and size caps are unchanged. Integration retains current main's separately indexed CSS action selectors.

Evidence

November 22 hosted CI

The required CI aggregate is failing on the unchanged published head cd70b08957ab6496e4448df351937c7f9997038f. The bundled UI failure matches the same assertion on the tested merge's exact main parent, b8a55ae92072dac7ec0c456a04831f7284e22170. The test expects Set up a model after a model authentication failure; #203394 intentionally changed that action to Open Models. This comparison classifies only that assertion; it does not establish that the replacement button passed in those runs.

Separately, performance CI failed during the baseline phase, before measuring a paired candidate delta. It does not establish a bundle-size regression from this PR or clear the performance requirement. No gate, budget, or assertion was waived.

Earlier local evidence

  • Static performance audit acceptance rule: compare the exact tested base 4aa0168 with this unchanged candidate using the repository comparison script, one installed toolchain and its fixed build identity. Attribute largest-JS, total-CSS and route-boot bytes against both base and unchanged thresholds; do not treat absolute overages as PR-introduced without a matched baseline. This is bundle-size evidence, not browser latency or codec proof.
  • Integrated through the supported managed base refresh onto official main 4aa0168; its single CSS conflict was resolved and the refresh finished cleanly.
  • Fresh current-lockfile run: 85 tests passed across 7 suites, exercising production controller/rendering, wrapper/worker failure paths, retry/cancellation/queue behavior, budgets with staged files, and ownership/handoff settlement. Controlled injections are not real WebCodecs proof.
  • Production UI typecheck, ui-chat and ui-e2e-chat test type graphs, targeted lint/style/catalog/format/whitespace checks passed.
  • Actual production UI build completed successfully after installing the current frozen lockfile. A portable real-frontend preview package was assembled with the hashed compression worker/assets, source, manifest, licenses, a local-only real-Gateway launcher and test matrix. Integrity checks and 32 static entry/worker HTTP requests passed; these are not browser or Gateway/model proof.
  • Fresh independent local review against the exact managed base covered P0 through P2 and returned scoped-clean with no actionable findings.
  • Current-day browser prerequisites remain blocked at the sandbox proc-fdinfo chroot operation (EPERM). No sandbox/TLS weakening, private recording, or paid runner was used.
  • Static audit: the exact tested base and candidate have identical manifests, lockfile, Vite configuration and performance reporters. The unmodified paired harness stopped before either build because extracting the 64,714-file base exhausted its 1 GiB temporary filesystem (tar: No space left on device). A report-only read of the retained candidate confirms the absolute overages below; no measured base or PR-attributable delta is available. Neither inherited debt nor PR-caused regression is asserted. Thresholds and source are unchanged.
  • Remaining validation before merge: screenshots/device qualification and performance-report overages. No budgets or assertions were weakened. An earlier pre-assertion native abort remains unresolved; the current bounded passing run is not claimed as its repair.
Current build advisory values

Largest JavaScript gzip: 558.4 KiB versus 553.7 KiB; total CSS gzip: 324.2 KiB versus 318.9 KiB; total CSS raw: 1666.1 KiB versus 1642.8 KiB; chat boot JavaScript gzip: 1280.4 KiB versus 1273.2 KiB; New Session boot JavaScript gzip: 794.1 KiB versus 787.0 KiB. The production build reports these without rejecting the build; performance-gate clearance is not asserted.

Requested by Daniil Karpenko.

Work sessions

Linked for team reference; these sessions aren’t public.

Worked on by

roboclaw-bot and others added 3 commits November 13, 2026 10:07
Co-authored-by: dankarization <26330178+dankarization@users.noreply.github.com>
Co-authored-by: dankarization <26330178+dankarization@users.noreply.github.com>
Worked on by:
- @dankarization

Co-authored-by: dankarization <26330178+dankarization@users.noreply.github.com>
OpenClaw-Publication: 37d3c1a4-6a59-493d-9072-ca27e509e93c
@clawsweeper

clawsweeper Bot commented Nov 13, 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.

@openclaw-barnacle openclaw-barnacle Bot added docs Improvements or additions to documentation app: web-ui App: web-ui size: L labels Nov 13, 2026
@dankarization

Copy link
Copy Markdown
Contributor

Any chrome, not only mobile.

@clawsweeper clawsweeper Bot added clawsweeper:intake:bug Preliminary submission classification; full source review pending. clawsweeper:intake:needs-environment Preliminary submission classification; full source review pending. clawsweeper:intake:needs-repro Preliminary submission classification; full source review pending. P2 Normal backlog priority with limited blast radius. rating: 🧂 unranked krab Not merge-ready due to missing proof or serious correctness/safety concerns. status: 👀 ready for maintainer look ClawSweeper has no concrete contributor-facing blocker left for this PR. and removed clawsweeper:intake:bug Preliminary submission classification; full source review pending. clawsweeper:intake:needs-environment Preliminary submission classification; full source review pending. clawsweeper:intake:needs-repro Preliminary submission classification; full source review pending. labels Nov 13, 2026
@clawsweeper

clawsweeper Bot commented Nov 13, 2026 •

Copy link
Copy Markdown
Contributor

Codex review: needs maintainer review before merge.

What this changes

This PR exposes video compression failure explanations and bounded diagnostic codes, and labels encoding and attachment preparation separately.

Example: Encoding finishes for screen.mp4, and reading the prepared copy reaches 3%.

  • Before: The tile still labels the progress as “Compressing · 3%”.
  • After: The tile displays “Preparing attachment · 3%”.

Review scores

Measure Result What it means
Overall readiness 🧂 unranked krab (1/6) The source change is coherent and has focused supporting tests, but required proof of the changed browser behavior is absent.
Proof confidence 🧂 unranked krab (1/6) Real behavior proof is not required for maintainer- or bot-authored pull requests.
Patch quality 🐚 platinum hermit (4/6) No actionable review findings were identified.

Product

Kind: Bug fix · Worth it: Yes · Fix scope: Complete
User problem: Chrome users cannot readily see why video compression failed, and reading the encoded copy appears to restart compression progress.
Reason: The maintainer-authored direction improves actionable feedback while preserving the intentionally compact card and recovery flow; it does not claim to repair the original codec failure.

Merge readiness

✅ Ready for maintainer review

Keep this maintainer-authored draft open: it addresses source-confirmed composer feedback defects, and no concrete introduced correctness or security bug was found.

Priority: P2
Reviewed head: cd70b08957ab6496e4448df351937c7f9997038f

Before merge

None.

Findings

None.

Tests

  • Missing end-to-end proof: Provide inspected before/after Chrome screenshots at mobile width and runtime evidence of the encoding-to-preparation transition and visible failure-to-retry flow on the served production UI, plus base-red/head-green regression evidence; redact sensitive details.
Agent review details

How this fits together

The Control UI attachment lifecycle admits selected files, runs optional video compression in a worker, reads the prepared copy into the draft, and projects progress and recoverable failures into the attachment tile.

flowchart LR
  A[Selected video] --> B[Attachment lifecycle]
  B --> C[Compression wrapper]
  C --> D[Encoder worker]
  D --> B
  B --> E[File reader]
  E --> F[Ready draft attachment]
  B --> G[Attachment tile]
Loading

Technical review

Best possible solution:

Keep the repair within the existing compression wrapper, attachment lifecycle, and tile while preserving their retry, cancellation, and admission contracts.

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

Current-main source establishes the hidden explanation and continued compressing label during FileReader progress; the reported approximately 30 MB encoding failure itself remains unreproduced and unroot-caused.

Is this the best way to solve the issue?

The scoped approach fits the existing owners: fixed diagnostic vocabulary crosses the worker boundary, the lifecycle records the phase, and the tile presents those facts without another upload path.

AGENTS.md: found and applied where relevant.

Codex review notes: model internal, reasoning medium; reviewed against 4a24e68929d1.

Provenance checked

Testing

Proof path: in-process harness.

Security

None.

Evidence

What I checked:

Likely related people:

  • Peter Steinberger: Raw commit f00f6a5 adds ui/src/pages/chat/components/chat-attachment-video.ts:1 relative to its recorded parents. This identifies author metadata, not feature responsibility or a PR merger. (role: source-line author; confidence: high; commits: f00f6a56a83a; files: ui/src/pages/chat/components/chat-attachment-video.ts)

PR surface

Source +128, Tests +291, Docs +5. Total +424 across 13 files. Added test files: 2.

View PR surface stats
Area Files Added Removed Net
Source 7 176 48 +128
Tests 5 300 9 +291
Docs 1 6 1 +5
Config 0 0 0 0
Generated 0 0 0 0
Other 0 0 0 0
Total 13 482 58 +424

Preflight source

Source unknown. Source comparison at the observed PR snapshot only. Completion is self-reported; body, policy, tests, execution, and report bytes are not verified.

Labels

Label changes:

No label changes.

Label justifications:

  • P2: Hidden compression explanations and mislabeled preparation progress cause bounded composer confusion while existing retry and removal remain available.
  • rating: 🧂 unranked krab: Overall readiness is 🧂 unranked krab; proof is 🧂 unranked krab and patch quality is 🐚 platinum hermit.
  • status: 👀 ready for maintainer look: ClawSweeper has no concrete contributor-facing blocker left for this PR.

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 November 13, 2026, 5:51 AM ET / 10:51 UTC.

@roboclaw-bot
roboclaw-bot marked this pull request as ready for review November 22, 2026 16:26

This branch has not been deployed

No deployments
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 docs Improvements or additions to documentation P2 Normal backlog priority with limited blast radius. rating: 🧂 unranked krab Not merge-ready due to missing proof or serious correctness/safety concerns. size: L status: 👀 ready for maintainer look ClawSweeper has no concrete contributor-facing blocker left for this PR.

2 participants