Repository navigation
improve(ui): show chat reply failures as a system line - #189807
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 changes before merge. What this changesThis PR replaces chat failure cards with a compact system line and floating, copyable error details. Example: A reply fails with “Provider response: 503 Service Unavailable.”
Review scores
ProductKind: Preference · Worth it: Yes · Fix scope: Complete Merge readiness⛔ Needs changes before merge - 1 item remains Keep this PR open: the maintainer-approved presentation improvement is useful, but its new effect violates the enforced controller guard and needs a focused repair. Priority: P3 Before merge
Findings
Tests
Agent review detailsHow this fits togetherThe Control UI renders terminal run failures from transcript projections; this component presents their diagnostics and delegates eligible retries and clipboard writes to existing owners. flowchart LR
A[Terminal run failure] --> B[Transcript projection]
B --> C[Failure system line]
C --> D[Shared Popover]
D --> E[Diagnostic and CopyButton]
C --> F[Existing retry owner]
Technical reviewBest possible solution: Keep the shared Popover design and bind its scroll/resize work through existing lifecycle callbacks or observer primitives without adding a per-view effect. Do we have a high-confidence way to reproduce the issue? The original component renders expanded details in normal flow, and the supplied before/after browser evidence demonstrates the presentation change; no target code was executed during review. Is this the best way to solve the issue? Reusing the existing Popover, clipboard feedback owner, and scroll-state observer is appropriate; the new effect can be replaced with existing lifecycle mechanisms. Full review comments:
Overall correctness: patch is incorrect AGENTS.md: found and applied where relevant. Codex review notes: model internal, reasoning medium; reviewed against efd616ac8ac5. Provenance checked
TestingProof path: shipped entry point. SecurityNone. EvidenceAcceptance criteria:
What I checked:
Likely related people:
PR surfaceSource +248, Tests +111. Total +359 across 9 files. Added test files: 1. View PR surface stats
Review metrics
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 31, 2026, 6:25 PM ET / 22:25 UTC. |
|
Merged via explicitly authorized admin squash with attributed pre-existing CI failures.
|
* improve(ui): show chat reply failures as a system line * fix(ui): keep reply failure logs left to right in RTL locales * fix(ui): bind error panel listeners to its open lifetime
What Problem This Solves
A failed reply shows as a tall amber block in the transcript, and opening its Details pushes the rest of the conversation down.
User Impact
User impact: a failed reply is now one centered line between two hairlines with Try again beside it. Selecting the line opens the summary and the full error in a floating panel, and the conversation does not move. The same copy, repeat count, retry eligibility and copied text apply.
Why This Change Was Made
The failure reads as a system event rather than a block of content, so it uses the system divider idiom. Details use the existing
Popover(native top layer and overlay anchor), so the panel is out of flow, is not clipped by the transcript scroller, and keeps the app's dismissal, focus and ARIA behavior on the menu surface tokens. The log fades use the existing scroll state observer.CopyButtongains an optional icon-only feedback mode for the well; other copy buttons are unchanged.Behavior worth reviewing:
hover: none.Evidence
Real app on a Vite source server with the mock Gateway. Every state comes from
chat.history,sessions.listandconfig.getat the data layer: nothing was inserted into or hidden in the page. Scrollbars are enabled in Chromium. Copied uses the real clipboard and was read back. Copy failed uses an init script that makes both clipboard transports report failure, as when the browser denies permission. The error text and the 1,280 repeated failures are mock data.Before is
b053d92e095, as 1280x800 full frames. After is46bc8dc09b6on06a71d75b01, cropped to the conversation at 2x, except 390 px which are full frames at 2x. The Before sidebar is empty only because this scenario has a single session.The follow-up
a1577855c7dchanges only direction handling. Against46bc8dc09b6, English Chromium captures keep the same line breaks. All five 1280 px states match byte for byte in both themes, apart from one light log frame that differs only in the faint animated background. At 390 px the second summary line moves by under a pixel.Nothing moves
Measured before opening, across the opening animation (6 samples), after scrolling the log and after Esc: next message top 276 px, transcript
scrollHeight646 px andscrollTop0 at every sample, a shift of 0.scrollHeight, closed to openscrollTop, closed to openRecording, Absolutely dark, Chromium: hover, open, scroll the log to its end, Esc.
reply-failure-after-video-page@88c8b7bf26530ccfe373e4b11153a43f.webm
Other measurements
backdrop-filtercomputes toblur(8px)and paints, so transcript text behind the panel is not readable, the same as behind the existing composer menu. The 10 px gutter holds a thumb with no track, the fades clear at each end of the log, and the panel is 460 px wide in the top layer. Near the composer it opens above.ar, Chromium and Safari 27.0.1 at 1280 and 390 px: log directionltr, summary directionrtl, panel centered on the line, copy at the well's right edge, document overflow 0. The chevron points at the panel.none, every sampled frame after the click is already fully open (42 frames, one distinct opacity, scale and rotation), and Esc hides the panel within 60 ms. Without it: 0.1 s, with 10, 10 and 7 distinct values.Absolutely dark
Absolutely light
CRT dark
CRT light
Beacon dark
Beacon light
Safari 27.0.1, Absolutely
Real Safari on macOS 27.0.1, window captures, with the same mock Gateway data. A small page script presses the real controls and sets the log's scroll position; it inserts and hides nothing. These are at
a1577855c7d, except Copied, which is a real press at46bc8dc09b6.Right to left, Absolutely
Locale
ar, ata1577855c7d. The mock error stays in English, as a provider error would. The Safari 390 px shots are a 390 px iframe of the same page, because a Safari window cannot be that narrow, cropped to that frame.Checks
Test changes:
chat-run-failure-noticeand the two e2e files now read the error from the well and open the panel through its toggle.chat-retry-failurereplaces the hover-revealed copy checks with open, Esc, outside click and no-shift checks, and keeps the 32 px touch check. The new browser test covers out-of-flow opening, Esc and outside click, flipping, closing on scroll, the fades, and the left-to-right well and isolated summary line in a right-to-left locale. No coverage was removed.Known gaps: