Repository navigation
Keep restored terminals out of another workspace cwd - #16248
Conversation
|
Warning Review limit reachedYou've used all free OSS reviews for now. Wait for the free limit to reset to keep reviewing this public repository. Next included review available in 18 minutes. View limit detailsLimit details: You’ve used all 10 included reviews currently available. Review configuration: ⚙️ Run configurationConfiguration used: Repository: manaflow-ai/cmux/.coderabbit.yaml Review profile: ASSERTIVE Plan: Advanced Run ID: 📒 Files selected for processing (2)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
|
All contributors have signed the CLA ✍️ ✅ |
CI failure attributionCI failed on
Matched log linesNot re-run automatically: Written by |
|
Merge receipt for
Labeled |
) #16248 resolves a missing local startup cwd to its nearest existing parent, so tests that requested fake /tmp or /repo paths saw "/tmp" or "/". Create those directories so the tests keep checking inheritance. Claude-Session: https://claude.ai/code/session_01FrR7YbsQtGw2eFtDeyiTcK Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com>
Summary
When a restored local terminal's saved worktree no longer exists, the startup resolver could fall through to the selected workspace's directory. An auto-resumed Claude/Codex command could then run in another repository.
Fixes #15804.
Testing
python3 scripts/verify-local.py --affected mf/main— 2/2 applicable checks passed.swiftc -parse Sources/RemoteTerminalWorkingDirectoryResolver.swiftswiftc -parse cmuxTests/WorkspaceTerminalWorkingDirectoryFallbackTests.swiftgit diff --checkNative app tests were not run on the MacBook Air; CI is intentionally not being monitored.
Changelog
Fixed: Restored agent terminals no longer resume in another workspace when their saved directory was deleted.
Need help on this PR? Tag
@codesmith-botwith what you need. Autofix is disabled.Summary by cubic
Fixes #15804: restored local terminals whose saved worktree no longer exists could resolve to the selected workspace's directory, letting an auto-resumed agent command run in a different repository.
Written for commit ce64259. Summary will update on new commits.