[BUG] «PowerShell tool в Code tab всегда возвращает Exit code 1 без вывода на любую команду (даже Write-Output test), при этом PowerShell в системе работает нормально
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?
Every PowerShell tool call in this session returns "Exit code 1" with zero
output, even for trivial no-op commands (e.g. Write-Output test,Get-Date, 1+1). A command writing to a file (Out-File) also produces
no file at all, confirming the shell process itself never runs — this is
not a script error. PowerShell works normally when run manually outside
Claude Code on the same machine. The issue persisted after fully closing
and restarting the Claude Code app, and also reproduces identically inside
a spawned subagent in the same session.
What Should Happen?
The PowerShell tool should execute the given command and return its actual
stdout/stderr and exit code — e.g. running Write-Output test should return
exit code 0 with output "test".
Error Messages/Logs
Steps to Reproduce
- Open Claude Code desktop app (Code tab), any project folder on Windows.
- Ask Claude to run any PowerShell command via its terminal tool.
- Observe: tool call returns only "Exit code 1", no stdout/stderr, no
side effects (files never get created).
Claude Model
None
Is this a regression?
Yes, this worked in a previous version
Last Working Version
_No response_
Claude Code Version
1.52386.6
Platform
Anthropic API
Operating System
Windows
Terminal/Shell
PowerShell
Additional Information
Windows 11 Home Single Language, PowerShell 5.1 (Windows PowerShell),
Claude Code desktop app (Code tab).
This issue has 2 comments on GitHub. Read the full discussion on GitHub ↗