[BUG] IDE integration fails with "workspace directories do not match" error despite identical paths

Status Fixed / completed
Maintainer reply None cached
Activity 3 comments · opened Jul 25, 2025 · closed Jul 29, 2025

## Environment

  • Platform (select one):
  • [x] Anthropic API
  • [ ] AWS Bedrock
  • [ ] Google Vertex AI
  • [ ] Other: <!-- specify -->
  • Claude CLI version: 1.0.60 (Claude Code)
  • Operating System: macOS (Darwin 26.0)
  • Terminal: VS Code integrated terminal

## Bug Description
The /ide command fails to connect to Windsurf IDE, reporting that workspace directories don't match even though the displayed paths are identical. The error message shows both paths as
/Users/<x>/Documents/GitHub/<xx> but still claims they don't match.

## Steps to Reproduce

  1. Open Windsurf IDE with a project at /Users/<x>/Documents/GitHub/<xx>
  2. Ensure Claude Code extension is installed and running in Windsurf
  3. Navigate to the same directory in terminal: cd /Users/<x>/Documents/GitHub/<xx>
  4. Run /ide command
  5. Observe the error message showing identical paths but claiming they don't match

Connect to an IDE for integrated development features. │
│ │
│ No available IDEs detected. Make sure your IDE has the Claude Code extension or plugin installed and is running. │
│ │
│ Found 1 other running IDE(s). However, their workspace/project directories do not match the current cwd. │
│ │
│ • Windsurf: /Users/<x>/Documents/GitHub/<xx>

## Expected Behavior
When the current working directory matches the IDE's workspace directory, the IDE integration should connect successfully without any errors.

## Actual Behavior
The command reports:
Found 1 other running IDE(s). However, their workspace/project directories do not match the current cwd.

• Windsurf: /Users/<x>/Documents/GitHub/<xx>
Despite the current working directory also being /Users/<x>/Documents/GitHub/<xx>.

## Additional Context

  • Verified paths are identical using pwd -P and realpath commands
  • Both paths resolve to: /Users/<x>/Documents/GitHub/<xx>
  • No symbolic links are involved in the path
  • Restarting Windsurf does not resolve the issue
  • The paths appear visually identical in the error output
  • This appears to be a path comparison logic issue in the IDE detection code

View original on GitHub ↗

3 Comments

OmniZenRaj · 1 year ago

I have the same issue on macos. I found that claude ide always uses the full path to the folder/workspace /Users/ranjit/DEV but vscode ide always used the home dir based path ~/DEV. I tried several ways to align them by forcing various path names explicitly, but the mismatch persisted. I finally used claude vscode extension and then opened it up as I would in my cli and the /ide command worked ok. I now prefer running inside vscode vs the command line because of the extra features. I hope this helps with Windsurf - i use that as well in vscode but not directly integrated with claude. Good luck.

theferrit32 · 1 year ago

I had this same problem in VSCode on MacOS. VSCode and the claude package and the VSCode Claude extension were up to date.

The claude package was at 1.0.63.

Then I went out to a terminal and did:

npm uninstall -g @anthropic-ai/claude-code
npm install -g @anthropic-ai/claude-code

Then exited and re-opened VSCode, and now it is working, even though the version it installed was 1.0.63, which is the same as was already there.

github-actions[bot] · 1 year ago

This issue has been automatically locked since it was closed and has not had any activity for 7 days. If you're experiencing a similar issue, please file a new issue and reference this one if it's relevant.