You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Windows sandbox instability: apply_patch intermittently fails with "windows sandbox: setup refresh failed with status exit code: 1" #16643
What version of the Codex App are you using (From “About Codex” dialog)?
26.325.31654
What subscription do you have?
plus
What platform is your computer?
Windows11
What issue are you seeing?
On Windows, file operations via PowerShell in the same workspace are stable, but Codex built-in apply_patch is intermittently failing.
Main error:
windows sandbox: setup refresh failed with status exit code: 1
Observed behavior:
apply_patch Add File sometimes succeeds, but Update/Delete often fails with the sandbox refresh error.
In some runs, even Add File fails immediately with the same error.
PowerShell create/write/read/delete in the same deep directories works normally.
This blocks normal coding workflows because built-in patching is unreliable.
What steps can reproduce the bug?
Open Codex App on Windows in workspace D:\Code\GolandProjects\tdem.
Use apply_patch to Add File: src/sandbox-tool/deep/probe.txt.
Use apply_patch to Update File on the same file.
Use apply_patch to Delete File on the same file.
In parallel, run PowerShell create/read/delete under src/ as control.
apply_patch should consistently support Add/Update/Delete inside writable workspace paths, with behavior matching stable shell file operations in the same session.
Additional information
Workspace: D:\Code\GolandProjects\tdem
Shell: PowerShell
Date observed: 2026-04-03
I also saw one update mismatch when file had UTF-8 BOM, but the main blocker is the recurring sandbox refresh failure.
Activity
github-actions commentedon Apr 3, 2026
Potential duplicates detected. Please review them and close your issue if it is a duplicate.
apply_patchfails on Windows after first write in sandbox-owned directory in VS Code Extension #15277Powered by Codex Action