Windows sandbox setup refresh fails with os error 740 for shell commands

Resolved 💬 2 comments Opened Jun 9, 2026 by martinmclee Closed Jun 9, 2026
💡 Likely answer: A maintainer (github-actions[bot], contributor) responded on this thread — see the highlighted reply below.

### Summary
Shell commands executed via Codex (example: rg --files) now fail immediately with:
execution error: Io(Custom { kind: Other, error: "windows sandbox: spawn setup refresh" }).

Running the same commands directly outside Codex succeeds, so this appears to be a Windows sandbox setup regression.

Observed log pattern

  • setup refresh: failed to spawn codex-windows-sandbox-setup.exe: The requested operation requires elevation. (os error 740)
  • Repeats on each command invocation before command output.

Versions

  • codex-cli: 0.137.0
  • Windows sandbox mode is configured as elevated

If helpful I can provide a full reproduction timeline.

View original on GitHub ↗

2 Comments

github-actions[bot] contributor · 2 months ago

Potential duplicates detected. Please review them and close your issue if it is a duplicate.

  • #26158
  • #25876
  • #27125
  • #26871
  • #25791

Powered by Codex Action

martinmclee · 2 months ago

Duplicate of #26158. This appears to be the same elevated sandbox regression with spawn setup refresh + os error 740 and command execution failing before running the payload.

Please continue tracking on #26158.