[BUG] VS Code extension installation fails with spaces in Windows username
Environment
- Platform (select one):
- [x] Anthropic API
- [ ] AWS Bedrock
- [ ] Google Vertex AI
- [ ] Other: <!-- specify -->
- Claude CLI version: 1.0.61 (Claude Code)
- Operating System: Windows 11
- Terminal: CMD
Bug Description
VS Code extension installation logic fails when Windows username contains spaces. Claude Code incorrectly treats the truncated username path as a VS Code extension ID and attempts to install it, resulting in installation errors despite successful connection.
Steps to Reproduce
- Have a Windows username that contains spaces (e.g., "nacl fish")
- Install Claude Code:
npm install -g @anthropic-ai/claude-code - Install VS Code extension manually:
code --install-extension anthropic.claude-code - Run Claude Code:
claude - Check IDE integration status with
/configcommand - Observe the installation error in IDE Integration section
Expected Behavior
Should handle usernames with spaces correctly and not attempt to install the truncated username as a VS Code extension ID. Should show proper installation status without errors.
Actual Behavior
IDE Integration • /config
✔ Connected to Visual Studio Code extension
⚠ Error installing VS Code extension: 1: 1 Extension 'c:\users\nacl' not found.
Make sure you use the full extension ID, including the publisher, e.g.: ms-dotnettools.csharp
Failed Installing Extensions: c:\users\nacl
The username "nacl fish" gets truncated to "nacl", and Claude Code incorrectly tries to install "c:\users\nacl" as a VS Code extension ID instead of recognizing it as a file path.
Additional Context
- Manual installation of the extension works:
code --install-extension anthropic.claude-code - The connection shows as successful despite the installation error
- This suggests the issue is in the installation verification/retry logic, not the core functionality
- VS Code version: 1.102.1
- This affects Windows users with spaces in their usernames, which is a common scenario
This issue has 4 comments on GitHub. Read the full discussion on GitHub ↗