[BUG] TUI emits strikethrough on arbitrary text - reproduces on 2.1.150 in both diff view and normal output
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?
When using claude cli it displays random ascii characters after using it a while.
What Should Happen?
Preflight Checklist
- [x] I have searched existing issues and this hasn't been reported in this specific form
- [x] This is a single bug report
- [x] I am using the latest version of Claude Code
What's Wrong?
The Claude Code TUI is rendering arbitrary text with strikethrough formatting where none was intended. It appears the renderer is emitting ANSI SGR 9 (or equivalent) around tokens that should not be styled at all.
This is NOT limited to the diff renderer. It fires in normal assistant chat output as well.
Two distinct repro patterns observed in the same session:
- Diff view, JavaScript keywords: In an added-line diff block (green/plus lines), the bare keywords
ifandreturnrender with a full strikethrough across the word. No surrounding tildes, no markdown syntax, no~characters anywhere in the line. The strikethrough is applied directly to the keyword tokens.
- Normal assistant output, underscored identifier in parentheses: In a regular response paragraph, a parenthesized identifier like
(wp_wqly_qlx_qmu_...)renders with strikethrough applied to every single character including the underscores. Surrounding text in the same line ("Backend", "now short-circuits") renders normally.
This appears related to but distinct from the GFM tilde-as-strikethrough reports in #19251 and #9757, both of which are currently marked stale. Those issues describe literal ~text~ wrapping triggering strikethrough. This report covers text that does not contain tildes at all.
What Should Happen?
Text should render without strikethrough unless the source content explicitly uses ~~strikethrough~~ GFM syntax. JavaScript keywords in diff output and underscored identifiers in normal prose should render as plain text with normal syntax highlighting.
Steps to Reproduce
Exact trigger is not yet isolated, but the bug fires reliably during:
- Reviewing proposed file edits where the diff contains JS keywords like
if/return/function - Reading normal assistant responses that include parenthesized identifiers with underscores
The bug persists across:
- New sessions
- /clear
- Restarting Claude Code
- Restarting the VS Code integrated terminal
Claude Code Version
2.1.150
VS Code Extension Version
2.1.150 (IDE bridge server 2.1.145)
Model
Opus 4.7 with 1M context
Platform
Anthropic API (Claude Max account)
Operating System
Windows 11
Terminal/Shell
VS Code integrated terminal on Windows 11
Additional Information
Reproduces on the latest CLI, latest VS Code extension, and current IDE bridge, so the differential renderer rewrite from late January 2026 did not address this case.
Related stale issues:
- #19251 (GFM tilde-as-strikethrough, reopened Jan 2026, stale)
- #9757 (original tilde-as-strikethrough, closed and locked Oct/Nov 2025)
Both describe the tilde-input case. This report adds a non-tilde input case that the existing reports do not cover. Screenshots attached showing both manifestations.
<img width="549" height="172" alt="Image" src="https://github.com/user-attachments/assets/aafbbd51-3fd9-44e7-92e1-87302d2df293" />
<img width="1219" height="316" alt="Image" src="https://github.com/user-attachments/assets/9c7046ad-d355-4bad-abb1-7455aade2d94" />
Error Messages/Logs
Steps to Reproduce
Use Claude CLI
Claude Model
Opus
Is this a regression?
Yes, this worked in a previous version
Last Working Version
_No response_
Claude Code Version
Claude Code CLI: 2.1.150 VS Code extension: 2.1.150 (server 2.1.145) Model: Opus 4.7 (1M context) OS: Windows 11 Terminal: VS Code integrated terminal Login: Claude Max
Platform
Anthropic API
Operating System
Windows
Terminal/Shell
VS Code integrated terminal
Additional Information
<img width="1219" height="316" alt="Image" src="https://github.com/user-attachments/assets/2b420433-7151-445d-a85b-22a6cb3fbc8d" />
<img width="549" height="172" alt="Image" src="https://github.com/user-attachments/assets/781b6a69-7cfc-4a0f-aed0-a7ba9bca2f08" />
This issue has 2 comments on GitHub. Read the full discussion on GitHub ↗