Repository navigation
fix(acp): long sign-in errors no longer end with a broken character - #48381
StiensWout wants to merge 5 commits into
Conversation
Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com>
Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com>
Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com>
Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com>
Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com>
|
No actionable comments were generated in the recent review. Walkthrough
Merge Risk:
|
ApprovabilityVerdict: Approved at Macroscope's review found this PR approvable — Long ACP sign-in error details now truncate at complete Unicode grapheme boundaries rather than splitting characters. The change is limited to error-message presentation and preserves the existing length limit. You can add or adjust custom eligibility rules. Learn more. |
When an ACP agent returns a sign-in error longer than 500 characters, the app shortens it. The cut counted UTF-16 units, so an emoji or flag at the limit was split, and the error ended with a replacement character (�) or half a flag before the ellipsis. The shortened message now ends at the last whole grapheme within the same 500-unit budget, so it never ends on a partial character.
Related: #44772, #48336
Reproduction on main
Commit 82eacef94b (main). The key emoji turns into a replacement character just before the ellipsis. Expected: The shortened error ends at a character boundary.
The cause is at
packages/provider-acp-registry/src/server/auth.ts:36. Ranpnpm scenarios:prove scripts/scenarios/acp-sign-in-error-keeps-whole-characters.e2e.ts --target webwith the repro scenario added: it failed in 2 of 2 runs on a clean boat.dev VM, withexpected "on refused�…" not to contain "�"in the output.Evidence
Environment: The web app in Chromium on Linux x64, a fresh checkout on a boat.dev VM reset before each run.
Proven: the repro fails at the test commit a97c685b65 and passes on the head 7ec341ba59, both on main 82eacef94b.
The key emoji turns into a replacement character just before the ellipsis.
The shortened error ends at a character boundary.
Tests
pnpm exec vp run check:changed 82eacef94bbaeb8a6b223e29efa1be3209025984passed on head.Not in this change
Who did the work
Made in T3 Code by Claude Opus 5.5 and GPT 6.2 Sol