PowerShell tool calls degrade terminal UI rendering for rest of session on Windows

Resolved 💬 2 comments Opened Apr 25, 2026 by stevenFiske Closed Jun 11, 2026

Environment

  • OS: Windows 11 Pro 26200
  • Shell: Windows PowerShell 5.1 (powershell.exe — what the PowerShell tool wraps)
  • Claude Code: 2.1.119

Reproduction

  1. Open a Claude Code session (any project directory)
  2. Send a prompt that triggers a PowerShell tool call (e.g., "list connected disks via Get-Disk")
  3. Observe: the Claude Code CLI rendering subtly changes — text becomes harder to read, looks like a font-style or font-size shift
  4. Subsequent prompts and subsequent tool calls (PowerShell or other) preserve the degraded rendering for the rest of the session
  5. Closing the window and resuming via claude --continue from a new window → rendering reverts to original

Expected
UI rendering remains consistent across tool calls regardless of which tool was invoked.

Actual
First PowerShell tool call mutates terminal rendering for the rest of the session. Bash tool calls do not trigger this.

Hypothesis
PowerShell 5.1's startup likely mutates parent-console state via Win32 APIs (e.g., SetCurrentConsoleFontEx, codepage change via chcp, or ENABLE_VIRTUAL_TERMINAL_PROCESSING console mode flag). The mutation persists at the console level — outliving the PS subshell — so subsequent rendering inside Claude Code uses the mutated state. New window = new console, hence the revert.

Workaround
Close window → claude --continue from a fresh window. Rendering resets.

Notes

  • Reproducible across multiple sessions on the same machine
  • Bash tool calls (Git Bash / mintty) do NOT trigger the issue, suggesting it's specific to how the PowerShell tool spawns its subshell with respect to Windows console state

View original on GitHub ↗

This issue has 2 comments on GitHub. Read the full discussion on GitHub ↗