[BUG] VS Code extension installation fails with spaces in Windows username
Resolved 💬 1 comment Opened Jul 26, 2025 by nacl-fishs Closed Jul 26, 2025
Bug Description
Expected Behavior:
Should handle usernames with spaces correctly and not attempt to install the truncated username as an extension ID
Actual Behavior:
- Username "nacl fish" gets truncated to "nacl"
- Claude Code incorrectly tries to install "c:\users\nacl" as a VS Code extension ID
- Installation fails with extension not found error
- However, the connection status shows successful (✔ Connected to Visual Studio Code extension)
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:
/config - Observe the installation error despite successful connection
Root Cause:
The installation logic incorrectly parses usernames with spaces and treats the truncated path as an extension ID to install.
Impact:
- Confusing error messages for users with spaces in Windows usernames
- May affect users' confidence in the integration even when it's working
- Installation logic needs proper path handling
Additional Context:
- Manual installation works:
code --install-extension anthropic.claude-code - Connection appears successful despite installation error
- This suggests the issue is in the installation verification/retry logic, not the core functionality
Environment Info
- Platform: win32
- Terminal: vscode
- Version: 1.0.61
- Feedback ID:
Errors
[{"error":"Error: 1: 1 Extension 'c:\\users\\nacl' not found.\nMake sure you use the full extension ID, including the publisher, e.g.: ms-dotnettools.csharp\nFailed Installing Extensions: c:\\users\\nacl\n\n at oO6 (file:///C:/Users/nacl%20fish/AppData/Roaming/nvm/v22.17.0/node_modules/@anthropic-ai/claude-code/cli.js:1345:4765)\n at process.processTicksAndRejections (node:internal/process/task_queues:105:5)\n at async sO6 (file:///C:/Users/nacl%20fish/AppData/Roaming/nvm/v22.17.0/node_modules/@anthropic-ai/claude-code/cli.js:1345:2187)","timestamp":"2025-07-26T13:19:39.457Z"},{"error":"Error: 403 {\"error\":{\"type\":\"forbidden\",\"message\":\"Request not allowed\"}}\n at i4.generate (file:///C:/Users/nacl%20fish/AppData/Roaming/nvm/v22.17.0/node_modules/@anthropic-ai/claude-code/cli.js:1317:7866)\n at DP.makeStatusError (file:///C:/Users/nacl%20fish/AppData/Roaming/nvm/v22.17.0/node_modules/@anthropic-ai/claude-code/cli.js:1334:2101)\n at DP.makeRequest (file:///C:/Users/nacl%20fish/AppData/Roaming/nvm/v22.17.0/node_modules/@anthropic-ai/claude-code/cli.js:1334:5315)\n at process.processTicksAndRejections (node:internal/process/task_queues:105:5)","timestamp":"2025-07-26T13:21:29.281Z"},{"error":"AxiosError: Request failed with status code 403\n at kq (file:///C:/Users/nacl%20fish/AppData/Roaming/nvm/v22.17.0/node_modules/@anthropic-ai/claude-code/cli.js:676:1077)\n at Unzip.Y0 (file:///C:/Users/nacl%20fish/AppData/Roaming/nvm/v22.17.0/node_modules/@anthropic-ai/claude-code/cli.js:677:9955)\n at Unzip.emit (node:events:530:35)\n at Unzip.emit (node:domain:489:12)\n at endReadableNT (node:internal/streams/readable:1698:12)\n at process.processTicksAndRejections (node:internal/process/task_queues:90:21)\n at x21.request (file:///C:/Users/nacl%20fish/AppData/Roaming/nvm/v22.17.0/node_modules/@anthropic-ai/claude-code/cli.js:679:2088)\n at process.processTicksAndRejections (node:internal/process/task_queues:105:5)\n at async gQ8 (file:///C:/Users/nacl%20fish/AppData/Roaming/nvm/v22.17.0/node_modules/@anthropic-ai/claude-code/cli.js:1539:467)\n at async Promise.all (index 0)\n at async file:///C:/Users/nacl%20fish/AppData/Roaming/nvm/v22.17.0/node_modules/@anthropic-ai/claude-code/cli.js:1525:6171","timestamp":"2025-07-26T13:21:29.600Z"}]This issue has 1 comment on GitHub. Read the full discussion on GitHub ↗