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
helper_unknown_error: setup refresh had errors #44309
appIssues related to the Codex desktop appbugSomething isn't workingtool-callsIssues related to tool callingwindows-osIssues related to Codex on Windows systems
What version of the Codex App are you using (From “About Codex” dialog)?
GPT-6 Astra
What subscription do you have?
Agent shell commands fail before execution with helper_unknown_error: setup refresh had errors. Restarting did not resolve it. The task’s workspace is C:\AI_Class_Sale. Git, Node.js, Prisma, and Docker work in external PowerShell.
What platform is your computer?
Windows 11
What issue are you seeing?
Agent shell commands fail before execution with helper_unknown_error: setup refresh had errors. Restarting did not resolve it. The task’s workspace is C:\AI_Class_Sale. Git, Node.js, Prisma, and Docker work in external PowerShell.
windows sandbox failed: helper_unknown_error: setup refresh had errors
What steps can reproduce the bug?
Use ChatGPT Codex and create a project and implement it - we will have the error after we create a first project with GPT 5 and a second project with GPT 6
The wok-around is to use Codex's PowerShell through approved -execution
The default sandbox runner fails
What is the expected behavior?
Should be able to access the files (R, W, E) in the project directoryproject
Additional data point: Codex App 0.155.0 on Windows. In a normal workspace, apply_patch first failed with fs sandbox helper failed with status exit code 1: windows sandbox failed: helper_unknown_error: setup refresh had errors. Later exec_command failed before launch with CreateProcess rejected / helper_unknown_error / setup refresh had errors. The problem was resolved only after downgrading Codex; it did not recover spontaneously or without a version change. Impact: no file patches and, temporarily, no commands could run. Docker services were healthy and external PowerShell commands still worked. No secrets, workspace paths, or logs attached.
A controlled investigation on another affected Windows installation reproduced the same top-level helper_unknown_error: setup refresh had errors symptom and separated several different failure layers.
Most relevant findings:
a default user-Temp ACL refresh failure was enough to block trusted runtime startup;
process-scoped TEMP/TMP=C:\CodexTemp restored trusted node_repl and native Windows Computer Use on that machine;
deeper ETW showed that SetNamedSecurityInfoW(...)=5 should not automatically be read as “the root SetSecurity itself was denied”;
synthetic controls also showed that top-level success can coexist with incomplete descendant ACL propagation.
So this is not claimed as a universal fix for every setup refresh had errors report, but if your sandbox log names user Temp/AppData or another ACL target, the diagnostics and workaround in #43373 may help distinguish the failure layer.
Do not change global Windows TEMP/TMP, ACLs, registry, or disable security software.
On the affected machine this changed sandbox refresh from SetNamedSecurityInfoW failed: 5 on the default Temp path to errors=[], after which trusted node_repl, @oai/sky, and native Windows Computer Use worked.
Important: this is not a universal fix for every setup refresh had errors; the same top-level error can have different causes. If your sandbox log points at another path, please post that exact failing path/error.
Problem: Codex returned helper_unknown_error: setup refresh had errors before running any command. Restarting Codex and the computer didn’t resolve it. The sandbox log showed an ACL failure on the project’s .codex folder.
Solution: Changing that folder’s owner to the Windows account restored workspace command access. I verified commands and Git status afterward. (⚠️This fix applies when the sandbox log shows an ACL failure on that project’s .codex folder.)
Close ChatGPT fully: File > Quit ChatGPT. Check Task Manager to make sure it isn’t still running; you may need to search for it.
Your path depends on where the project is set in GPT’s workspace settings. Many worktrees may be on C:, for example: C:\Users\abeward\.codex\worktrees\your-worktree-gpt-made\repo-name\.codex. You can ask GPT to help find the correct path, but target the specific repo with the sandbox issue. Run whoami by itself to find your Windows account name.
Look for Successfully processed 1 files; Failed processing 0 files.
Reopen ChatGPT/Codex and have it try again. This worked for me.
appIssues related to the Codex desktop appbugSomething isn't workingtool-callsIssues related to tool callingwindows-osIssues related to Codex on Windows systems
Activity
github-actions commentedon Sep 9, 2026
Potential duplicates detected. Please review them and close your issue if it is a duplicate.
Powered by Codex Action
lynnysk commentedon Sep 11, 2026
I can reproduce this on Codex Desktop for Windows.
Get-Location.helper_unknown_error: setup refresh had errorsduring sandbox setup.Exact error:
Expected: the Windows sandbox/helper should initialize and permit scoped local commands to run.
ragePolpette commentedon Sep 18, 2026
Additional data point: Codex App 0.155.0 on Windows. In a normal workspace, apply_patch first failed with fs sandbox helper failed with status exit code 1: windows sandbox failed: helper_unknown_error: setup refresh had errors. Later exec_command failed before launch with CreateProcess rejected / helper_unknown_error / setup refresh had errors. The problem was resolved only after downgrading Codex; it did not recover spontaneously or without a version change. Impact: no file patches and, temporarily, no commands could run. Docker services were healthy and external PowerShell commands still worked. No secrets, workspace paths, or logs attached.
Freemlen commentedon Sep 19, 2026
Related Windows RCA: #43373.
A controlled investigation on another affected Windows installation reproduced the same top-level
helper_unknown_error: setup refresh had errorssymptom and separated several different failure layers.Most relevant findings:
TEMP/TMP=C:\CodexTemprestored trustednode_repland native Windows Computer Use on that machine;SetNamedSecurityInfoW(...)=5should not automatically be read as “the root SetSecurity itself was denied”;So this is not claimed as a universal fix for every
setup refresh had errorsreport, but if your sandbox log names user Temp/AppData or another ACL target, the diagnostics and workaround in #43373 may help distinguish the failure layer.zLanp1e commentedon Sep 20, 2026
所以现在有什么直接的解决方法吗
Freemlen commentedon Sep 21, 2026
Yes — there is a practical workaround if your sandbox log shows the failure on the normal user Temp path (for example
%LOCALAPPDATA%\Temp).Verified on another affected Windows machine:
C:\CodexTemp.Do not change global Windows TEMP/TMP, ACLs, registry, or disable security software.
On the affected machine this changed sandbox refresh from
SetNamedSecurityInfoW failed: 5on the default Temp path toerrors=[], after which trustednode_repl,@oai/sky, and native Windows Computer Use worked.Important: this is not a universal fix for every
setup refresh had errors; the same top-level error can have different causes. If your sandbox log points at another path, please post that exact failing path/error.Full investigation and A/B evidence: #43373
如果你的 sandbox 日志明确显示失败发生在普通用户的 Temp 路径(例如
%LOCALAPPDATA%\Temp),目前有一个已验证的临时解决办法:C:\CodexTemp;TEMP/TMP,不要修改 Windows 全局环境变量。不要改全局 TEMP/TMP、不要递归修改 ACL、不要改注册表,也不要关闭 ESET/Defender。
这个方法在一台受影响的 Windows 机器上已验证成功:sandbox refresh 恢复正常,随后
node_repl、@oai/sky和原生 Windows Computer Use 都可以工作。但这不是所有
setup refresh had errors的通用修复。如果你的日志里报错的是其他路径,请把那个具体路径和错误贴出来。完整 RCA:#43373fix(gate): classify Codex Windows sandbox-unavailable as non-retryable (
abeward commentedon Oct 11, 2026
I also had this issue.
Problem: Codex returned
helper_unknown_error: setup refresh had errorsbefore running any command. Restarting Codex and the computer didn’t resolve it. The sandbox log showed an ACL failure on the project’s.codexfolder.Solution: Changing that folder’s owner to the Windows account restored workspace command access. I verified commands and Git status afterward. (⚠️ This fix applies when the sandbox log shows an ACL failure on that project’s
.codexfolder.)Close ChatGPT fully: File > Quit ChatGPT. Check Task Manager to make sure it isn’t still running; you may need to search for it.
Open PowerShell as Administrator, then run:
For me, the command was:
Your path depends on where the project is set in GPT’s workspace settings. Many worktrees may be on C:, for example:
C:\Users\abeward\.codex\worktrees\your-worktree-gpt-made\repo-name\.codex. You can ask GPT to help find the correct path, but target the specific repo with the sandbox issue. Runwhoamiby itself to find your Windows account name.Look for
Successfully processed 1 files; Failed processing 0 files.Reopen ChatGPT/Codex and have it try again. This worked for me.