Repository navigation
feat(ui): transcode renditions and waveform audio cards - #116115
Conversation
|
Codex review: needs real behavior proof before merge. Reviewed July 29, 2026, 7:29 PM ET / 23:29 UTC. ClawSweeper reviewWhat this changesThis PR adds Control UI audio and video cards that wait for transcoded renditions, refresh managed-media tickets, render bounded audio waveforms, and retain an explicit download fallback. Merge readiness⛔ Blocked until real behavior proof from a real setup is added - 4 items remain Keep this PR open for normal maintainer review. The patch has focused test and build evidence, but the current PR body still lacks directly inspectable after-fix Control UI proof for native playback, transcoded preparation/success, and the unavailable/download fallback; the existing Priority: P2 Review scores
Verification
How this fits togetherControl UI chat normalizes assistant and managed-media attachment records, resolves authenticated media URLs, and renders audio or video cards in the chat transcript. The new rendition-readiness path decides whether browser playback can begin, remains in preparation, or exposes a visible fallback. flowchart LR
A[Assistant or managed attachment] --> B[Chat message normalization]
B --> C[Attachment availability]
C --> D[Ticketed media URL]
D --> E[Rendition readiness check]
E --> F[Audio or video card]
F --> G[Inline playback]
E --> H[Visible download fallback]
Before merge
Agent review detailsSecurityNone. PR surfaceSource +1466, Tests +1385. Total +2851 across 24 files. View PR surface stats
Review metricsNone. Stored data modelPersistent data-model change detected: Mantis proof suggestionA redacted web UI chat transcript or recording would directly demonstrate the three user-visible states that automated tests cannot prove in a browser runtime. A maintainer can ask Mantis to capture proof by posting this exact PR comment: Merge-risk optionsMaintainer options:
Technical reviewBest possible solution: Add one redacted Control UI chat recording or equivalent live evidence that shows native playback, rendition preparation followed by successful playback, and the unavailable state retaining a usable download path; then let a maintainer assess the feature’s final UX and scope. Do we have a high-confidence way to reproduce the issue? Not applicable: this PR proposes a new Control UI playback capability rather than reporting a currently failing behavior with a single reproduction path. The PR includes focused automated coverage for its intended flows, but that is not a live browser reproduction. Is this the best way to solve the issue? Unclear: the readiness and fallback design is plausible and bounded, but real Control UI evidence is still required to establish that it is the best user-facing solution across the native, transcoded, and unavailable states. AGENTS.md: found and applied where relevant. Codex review notes: model internal, reasoning high; reviewed against 342826b90440. LabelsLabel justifications:
EvidenceWhat I checked:
Likely related people:
Rank-up movesOptional improvements that raise the rating; they are not merge blockers.
Rating scale
Overall follows the weaker of proof and patch quality. Workflow
HistoryReview history (1 earlier review cycle)
|
|
Merged via squash.
|
) * feat(ui): add chat media renditions and waveforms * fix(ui): tighten media playback guards * fix(ui): bound waveform decode memory * fix(ui): harden media playback retries * fix(ui): preserve valid media state * fix(ui): stop detached video playback * fix(ui): bound media artifact resolution * fix(ui): reject failed media fallback sources * refactor(ui): split attachment availability helpers * fix(ui): unload media across auth resets * fix(ui): retain the longest-lived media ticket
What Problem This Solves
Control UI chat messages can contain audio and video formats that browsers cannot play directly, leaving users with a generic attachment or download path instead of reliable inline playback. Long audio responses also lacked a useful waveform and playback timeline.
Why This Change Was Made
This adds transcode-aware audio and video cards, managed-media ticket refresh, bounded readiness checks, and waveform rendering while keeping the original attachment available as the explicit fallback. Media source state now survives safe ticket refreshes without retaining failed or cross-authentication playback state.
User Impact
Users can play assistant audio and video inline in the web Control UI, see preparation and unavailable states instead of silent failure, and navigate long audio with a waveform-backed timeline. Part of #115590.
Evidence
origin/mainat54e273e6953; PR head isa844e3e10517fea2324558ab050f6ad5b29381ff.node scripts/run-vitest.mjs ui/src/pages/chat/components/chat-audio-player.test.ts ui/src/pages/chat/components/chat-video-player.test.ts ui/src/pages/chat/components/chat-audio-waveform.test.ts ui/src/pages/chat/components/chat-message.test.ts— 4 files, 181 tests passed.node scripts/run-vitest.mjs ui/src/pages/chat/components/chat-media-source.test.ts ui/src/pages/chat/components/chat-audio-player.test.ts ui/src/pages/chat/components/chat-video-player.test.ts— 3 files, 33 tests passed.pnpm ui:buildpassed on Blacksmith Testboxtbx_01kyr2zmtsf0cbrge7tcgfbq5c, including precompressed-asset and Control UI performance checks: https://github.com/openclaw/openclaw/actions/runs/30499322303.