[BUG] claude --version (and all commands) spin at 100% CPU immediately on startup — Ubuntu 22.04 cloud VM, reproduced on 2.1.150 and 2.1.197

Open 💬 0 comments Opened Jul 1, 2026 by fisht99

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?

claude --version enters a 100% CPU spin immediately on startup and never returns — no output, no error, no crash. The process is in state R (running, not sleeping/blocked), confirmed via top. This happens before any REPL/UI is rendered and before any network call is made. Ctrl+C does not stop it; requires kill -9.

What Should Happen?

claude --version should print the version string and exit near-instantly, using negligible CPU.

Error Messages/Logs

Steps to Reproduce

Fresh install: npm install -g @anthropic-ai/claude-code --foreground-scripts (npm/Node via nvm, clean environment)
Run claude --version
Process immediately pins at ~100% CPU and never returns output

Claude Model

None

Is this a regression?

I don't know

Last Working Version

_No response_

Claude Code Version

2.1.197

Platform

Anthropic API

Operating System

Ubuntu/Debian Linux

Terminal/Shell

VS Code integrated terminal

Additional Information

_No response_

View original on GitHub ↗