Repository navigation
fix: restore supported image pastes in chat - #154367
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 maintainer review before merge. Reviewed September 21, 2026, 12:08 AM ET / 04:08 UTC (Revision 2). ClawSweeper reviewWhat this changesThe shared chat attachment parser separates an image data URL’s header from its payload while preserving decoding and attachment-size checks. Merge readiness✅ Ready for maintainer review Keep open: this is a focused repair candidate, current main retains the older parser, and no introduced correctness defect was found. The maintainer-authored PR is also protected from automated closure. Priority: P2 Review scores
Verification
How this fits togetherThe Control UI converts pasted image data URLs into attachments shared by chat and new-session composers. Accepted images enter the existing attachment store and preview flow before submission. flowchart LR
A[Clipboard image data URL] --> B[Parse image header]
B --> C[Decode base64 payload]
C --> D{Attachment size accepted}
D -->|Yes| E[Attachment store and preview]
D -->|No| F[Rejection notice]
Before mergeNone. Agent review detailsSecurityNone. PR surfaceSource +1. Total +1 across 1 file. View PR surface stats
Review metricsNone. Technical reviewBest possible solution: Keep image parsing in the shared attachment owner, avoiding a payload-wide regular-expression capture while retaining existing admission and decoding behavior. Do we have a high-confidence way to reproduce the issue? No independently confirmed current-main reproduction was established here. The existing 4 MiB textarea-paste regression provides a concrete check, and the author reports its Linux failure, but this read-only review did not execute it. Is this the best way to solve the issue? Yes: the patch makes a small change in the existing shared parser and preserves its accepted input and rejection checks; the platform-specific failure mechanism was not independently reproduced. AGENTS.md: found and applied where relevant. Codex review notes: model internal, reasoning medium; reviewed against 99112ab00fe8. LabelsLabel justifications:
EvidenceWhat I checked:
Likely related people:
Rating scale
Overall follows the weaker of proof and patch quality. Workflow
HistoryReview history (1 earlier review cycle)
|
|
Merged via squash.
|
What Problem This Solves
Fixes supported image data URL pastes failing before an attachment is added to chat.
User Impact
Supported pasted images reach the attachment flow reliably.
Why This Change Was Made
The clipboard parser now recognizes the image header separately from the payload. It retains the existing decoding, image-type and attachment-size checks.
Evidence
The full-suite benchmark was stopped after separate Chromium launch failures were traced to its temporary-directory setup. A full-suite pass is not claimed here.