[Windows] Persistent bun.exe terminal window with "Cannot read file System32" EPERM error
Resolved 💬 4 comments Opened Feb 5, 2026 by sanghyun-io Closed Mar 5, 2026
Description
When running Claude Code on Windows, a persistent terminal window spawns and remains open showing an error:
- Window title:
C:\Users\QESG\.bun\bin\bun.exe - Error message:
error: Cannot read file "C:\Windows\System32\": EPERM
Behavior
- The terminal window spawns during any Claude Code operation (no specific trigger identified)
- Window persists - it does not flash/disappear like other reported window issues
- Only one window appears at a time (never 2+)
- If manually closed, it reappears at some point during the session
- Does not seem to affect Claude Code functionality otherwise
Screenshot
<img width="979" height="512" alt="Image" src="https://github.com/user-attachments/assets/2953e94b-0fcf-4000-9fce-48a0460a9b06" />
(Terminal window showing the EPERM error)
Environment
- OS: Windows 10 (MINGW64_NT-10.0-19045 3.5.4)
- Claude Code version: 2.1.31
- Bun version: 1.3.8
- Node version: v22.21.1
- Install method: native
Steps to Reproduce
- Run Claude Code on Windows
- Perform any operation (chat, tool execution, etc.)
- At some point, the bun.exe terminal window appears with the EPERM error
- Window stays open until manually closed
- Eventually reappears
Expected Behavior
No external terminal window should spawn, or if a process needs to run, it should be hidden (windowsHide: true).
Additional Context
- Plugins enabled: context7, plugin-dev, ralph-wiggum, claude-hud
- Custom statusLine configured (uses Node, not Bun directly)
- No custom MCP servers configured
Related Issues
- #14828 - Console window flashing (different: flashing vs persistent)
- #19012 - Hook window flash (different: no error, just flash)
- #14242 - EPERM error (different: mkdir error, not System32 read)
This issue has 4 comments on GitHub. Read the full discussion on GitHub ↗