claude-code icon indicating copy to clipboard operation
claude-code copied to clipboard

[BUG] Copied text contains extra formatting spaces/chars (v2)

Open dhunt-xsolla opened this issue 3 months ago • 5 comments

Preflight Checklist

  • [x] I have searched existing issues and this hasn't been reported yet
  • [x] This is a single bug report (please file separate reports for different bugs)
  • [x] I am using the latest version of Claude Code

What's Wrong?

Reviving https://github.com/anthropics/claude-code/issues/5097 + https://github.com/anthropics/claude-code/issues/4686 that were both closed as dupes, but 1 of them should have survived. Inside has all the required info.

Now, we're on v1.0.65

TL;DR: If I copy a multi-line snippet of code, it has extra junk that messes up the code/snippet.

What Should Happen?

Snippets of code should be delicately wrapped for easy and expected copy without bloaty left-hand chars or other unrelated artifacts

Error Messages/Logs


Steps to Reproduce

  1. Ask it to print a multi-line hello world with really long chars
  2. Copy it
  3. Paste somewhere else - it will be different

Claude Model

Sonnet (default)

Is this a regression?

No, this never worked

Last Working Version

No response

Claude Code Version

v1.0.65

Platform

Anthropic API

Operating System

Windows

Terminal/Shell

Windows Terminal

Additional Information

Windows+WSL bash both experiences this


Image

Notice the trailing two spaces on the left before the {. Every line is like this

dhunt-xsolla avatar Nov 04 '25 08:11 dhunt-xsolla

CC dstolts, IsThatLegal, Letiliel, freyjay that participated in the other threads

dhunt-xsolla avatar Nov 04 '25 08:11 dhunt-xsolla

This issue has been inactive for 30 days. If the issue is still occurring, please comment to let us know. Otherwise, this issue will be automatically closed in 30 days for housekeeping purposes.

github-actions[bot] avatar Dec 09 '25 10:12 github-actions[bot]

There's nothing else to add - awaiting a dev to respond. @bcherny

dhunt-xsolla avatar Dec 09 '25 12:12 dhunt-xsolla