First of all, it tried to rewrite full files instead of just using mv - Not for teh first time. When I pointed it to use mv explicitely, it failed due to some “sandbox”:
Use bash mv do NOT rewrite full files
Plan: move docs using mv (no rewrites), then do small, surgical edits to homepage/README.md to remove calendar-specific fragments and replace them with a pointer to Web/site/apps/calendar/.
mkdir -p Web/site/apps/calendar/DOCS/setupGuide Web/site/apps/calendar/DOCS/API Web/site/apps/calendar/DOCS/userStories Web/site/apps/calendar/DOCS/architecture && mv -f Web/site/apps/calendar/SETUP.md Web/site/apps/calendar/SETUP.generated.md && mv -f Web/site/apps/homepage/DOCS/gmail-oauth-localhost-setup.md Web/site/apps/calendar/SETUP.md && mv -f Web/site/apps/homepage/DOCS/google-calendar-auth-service-accounts.md Web/site/apps/calendar/DOCS/setupGuide/google-calendar-auth-service-accounts.md && mv -f Web/site/apps/homepage/DOCS/google-calendar-api-freebusy-and-events.md Web/site/apps/calendar/DOCS/API/google-calendar-api-freebusy-and-events.md && mv -f Web/site/apps/homepage/DOCS/CalendarPlan/clientUserStories.md Web/site/apps/calendar/DOCS/userStories/clientUserStories.md && mv -f Web/site/apps/homepage/DOCS/CalendarPlan/adminUserStories.md Web/site/apps/calendar/DOCS/userStories/adminUserStories.md && mv -f Web/site/apps/homepage/DOCS/CalendarPlan/calendarArchitecture.md Web/site/apps/calendar/DOCS/architecture/calendarArchitecture.md && mv -f Web/site/apps/homepage/DOCS/CalendarPlan/calendarFlows.md Web/site/apps/calendar/DOCS/architecture/calendarFlows.md && mv -f Web/site/apps/homepage/DOCS/CalendarPlan/calendarDiagrams.md Web/site/apps/calendar/DOCS/architecture/calendarDiagrams.md && rmdir Web/site/apps/homepage/DOCS/CalendarPlan || true
The move command failed due to a Windows/Git Bash sandbox permission issue (“CreateFileMapping … error 5”). I’m going to rerun the same mv sequence outside the sandbox so the file moves can complete cleanly.
Steps to Reproduce
Ask Cursor to migrate large amount of code files from one folder to another.
Expected Behavior
Cursor will just use mv instantly, with no issues. It shoudl still show accept/deny for mv command if not on allowlist.
I am facing similar issues.
I am using auto-run in sandbox .
I asked agent to check some files and it auto ran command in the sandbox.
But all shell command failed and it reports like this.
In the past, if the agent has no permission to run the command, it will ask me for permisson.
But now, it will show success.
$ cd /Users/willis/MEPSDK/githubrelease/github && git ls-remote --tags origin | grep -E “10.6.(1|3)”
–: eval: line 1: unexpected EOF while looking for matching `)’
–: eval: line 2: syntax error: unexpected end of file
–: dump_bash_state: command not found
Windows + Git Bash: Sandbox isn’t fully compatible with the Git Bash/MSYS environment yet, which is why you’re seeing the CreateFileMapping error.
macOS: The dump_bash_state: command not found and unexpected EOF errors are also a known bug with the Sandbox terminal.
Workaround: For now, you can turn off “Auto-run in Sandbox” in settings (Cursor Settings > Features > Terminal > Auto-run) and use the normal mode with command confirmation.
The team is aware of both issues. I’ve added your reports, it helps with prioritization.
I was having this same issue. And from memory, this was new issue for me as well. I say “was” because I started fiddling with settings and now the issue is gone, I can run commands in Git Bash again. I don’t know what exactly I did to fix it.
There is no “Auto-run in Sandbox” option I can see in the Cursor settings. So that suggestion added to my confusion about what’s happening.
I don’t see any “Sandbox” settings in the VS Code portion of the settings either. I did have “Auto-Run Mode” enabled when I saw this issue. Now that option is set to “Ask Every Time” and commands are working again. I’m just not 100% sure that’s the setting that makes it work because I was moving other things around as well. I’m too scared to try to figure out exactly what it was since things are working now.
I’ve encountered a similar problem. The agent often fails to use cargo, even though it worked fine in the previous turn. The environment variables printed by the agent are::
rustup show && which cargo
Default host: x86_64-apple-darwin
rustup home: /var/folders/gs/5_v3733n13s6vxjqldmj8zhm0000gn/T/cursor-sandbox-cache/f243d0f211ce1a38dee7a08f13a2abe5/rustup
installed toolchains
--------------------
active toolchain
----------------
no active toolchain
/Users/xxx/.cargo/bin/cargo
Me too, started today - was fine previously. Agent wanted to apply some git commands as I migrate a large codebase, they all got this error 5.
I had an explicit chat with the agent about it (because… 2027) and it tried some Allowlisted commands (e.g. ls) without issue, and then a likely denied one:
The issue disappeared today.
I turned off “Auto-run in Sandbox” in settings, but I felt tired in clicking allow.
So I turned on “Auto-run in Sandbox” again and the issue disappeared.
I am not sure if it works because I restarted cursor and my mac as well.