/remote-control stuck at 'connecting…' when project has .git directory
Bug description
/remote-control (aka /rc) gets stuck at "Remote Control connecting…" and never establishes a connection when the project directory contains a .git directory.
This is a regression — /rc previously worked fine with git repositories.
Reproduction steps
- Open a project that is a git repository (has
.git/) - Run
claude --dangerously-skip-permissions - Run
/rc - Observe: stuck at "Remote Control connecting…" indefinitely
Workaround: Temporarily rename .git → .git_bak before starting Claude Code, run /rc, then restore .git. The connection stays active after restoring .git.
Environment
- Claude Code: v2.1.81
- OS: macOS (Darwin 24.3.0, arm64)
- Install method: Homebrew
Investigation details
Tested across 7 projects running simultaneously in tmux sessions:
| Project | Has .git | /rc result |
|---------|----------|------------|
| project-A | No | ✅ Connected |
| project-B | No | ✅ Connected |
| project-C | No | ✅ Connected |
| project-D | Yes (3.5MB) | ❌ Stuck at connecting |
| project-E | Yes (128K) | ❌ Stuck at connecting |
| project-F | Yes (11MB) | ❌ Stuck at connecting |
Ruled out
- Concurrent session limit: Disconnecting working sessions didn't help failing ones
- Stale session data: Cleaning
~/.claude/projects/session files didn't help - Uncommitted changes:
git stash --include-untracked(clean working tree) didn't help .gitsize: project-E's.gitis only 128K, still fails- Project size: project-E is 268K total, still fails
- settings.local.json: No correlation with presence/absence
Confirmed
- Renaming
.git→.git_bakbefore launch →/rcconnects successfully - Restoring
.gitafter/rcconnects → connection stays active - 100% reproducible across all 3 git repos, 0% failure on non-git projects
This issue has 2 comments on GitHub. Read the full discussion on GitHub ↗