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

[Bug] Terminal Rendering Fails for [Label]:Key Patterns

Open MaxFouTech opened this issue 1 year ago • 3 comments

Bug Description Claude Code Terminal Fails to Render [Label]:Key Pattern

Summary

The Claude Code terminal interface fails to display any assistant message that consists exclusively of a string matching the [Label]:Key pattern. The assistant generates the correct output, but the client does not render it.

Regex of Non-Rendering Pattern

The bug is triggered by any message that is a complete and exact match for the following regex:

^[[^]]+]:[^ ]+$

Where:

^[ → Starts with [

[^]]+ → The Label: one or more of any character except ]

]: → A literal closing bracket and colon

[^ ]+ → The Key: one or more of any character except a space

$ → End of the string

Observed Behavior (Rendering Failure)

Any message from the assistant that perfectly matches the structure above fails to display. Examples include:

User Prompt: just reply [TEST]:TEST

Assistant's (Hidden) Reply: [TEST]:TEST

User Prompt: just reply [TE ST]:TEST

Assistant's (Hidden) Reply: [TE ST]:TEST

User Prompt: just reply [123]:abc

Assistant's (Hidden) Reply: [123]:abc

User Prompt: just reply [key]:value123

Assistant's (Hidden) Reply: [key]:value123

Correctly Rendered Cases

The terminal correctly displays the assistant's output as long as it does not exclusively match the pattern.

When additional text is present:

Prompt: just reply [TEST]:TEST HELLO

Displayed Reply: [TEST]:TEST HELLO

When the string does not match the pattern:

Prompt: just reply HELLO

Displayed Reply: HELLO

Expected Behavior

All outputs generated by the assistant should be rendered correctly in the terminal, regardless of whether they conform to the [Label]:Key structure.

Environment Info

  • Platform: darwin
  • Terminal: Apple_Terminal
  • Version: 1.0.123
  • Feedback ID: 6cf6fd4a-f30d-4cb4-bf8c-04b729660dda

Errors

[]

MaxFouTech avatar Sep 24 '25 20:09 MaxFouTech

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 06 '25 10:12 github-actions[bot]

This issue has been automatically closed due to 60 days of inactivity. If you're still experiencing this issue, please open a new issue with updated information.

github-actions[bot] avatar Jan 09 '26 10:01 github-actions[bot]

This issue has been automatically locked since it was closed and has not had any activity for 7 days. If you're experiencing a similar issue, please file a new issue and reference this one if it's relevant.

github-actions[bot] avatar Jan 16 '26 14:01 github-actions[bot]