Codex for Windows sandbox repeatedly failconfig.toml
What version of the Codex App are you using (From “About Codex” dialog)?
windowsx64
What subscription do you have?
chat gpt plus
What platform is your computer?
Microsoft Windows NT 10.0.22631.0 x64
What issue are you seeing?
What happened
Codex had previously created a working Windows sandbox while my proxy was using port 7890.
On
The logs reported a
stored_ports=[7890]
and:
desired_ports=[]
Codex later disabled the sandbox in config.toml:
[windows]
sandbox = "disabled"
The file also contained a comment indicating that the sandbox installer had repeatedly failed with:
The specified module could not be found
I manually changed the setting to:
[windows]
sandbox = "elevated"
Codex attempted to configure the administrator sandbox, but displayed:
Unable to set up the Agent sandbox with administrator privileges.
You can continue using the non-administrator sandbox.
The non-administrator sandbox setup also failed:
Unable to set up the non-administrator sandbox.
I confirmed that both
C:\Users\<username>\.codex\config.toml
was valid TOML content, and:
C:\Users\<username>\.codex\.sandbox\setup_marker.json
was valid J
I then updated the Codex application. After the update, the
However, attempting to create a task or start a conversation produced this error:
failed to read configuration layers:
C:\Users\<username>\.codex\config.toml:112:44:
unclosed table, expected ]
I manually attempted to repair the affected table header by inserting a sing
After
Actual result
The administra
The non-adm
Code
After updating Codex, the sandbox setup prompt disappeared, but config.toml cou
After manually repairing the apparent syntax issue, conversations remain stuck loading and n
Codex is currently unusable.
Expect
Codex should correctly synchronize the sa
A change from proxy port 7890 to
Sandbox setup failures should provide a detailed and current
Codex should validate config.toml safely and identify the exact malformed project table.
Updating Codex should not leave the application in a state where the sandbox warning disappears but task
Invalid configuration should produce a recoverable error rather than an indefinite loading state.
Relevant log messages
sandbox setup required: offline firewall settings changed
(stored_ports=[7890], desired_ports=[], stored_allow_local_binding=false, desired_allow_local_binding=false)
The specified module could not be found
Unable to set up the Agent sandbox with administrator privileges
Unable to set up the non-administrator sandbox
failed to read configuration layers:
C:\Users\<username>\.codex\config.toml:112:44:
unclosed table, expected ]
Possible cause
This appears to involve a stale Windows sandbox marker or firewall state created while the system proxy used port 7890. A newer Codex version detected no required proxy ports, causing the stored sandbox state and the desired state to disagree.
The subsequent configuration parsing problem may be separate, but it occurred during the same recovery
What steps can reproduce the bug?
<img width="843" height="557" alt="Image" src="https://github.com/user-attachments/assets/742501a1-3219-4871-8fbf-2327458238b6" />
What is the expected behavior?
_No response_
Additional information
<img width="843" height="557" alt="Image" src="https://github.com/user-attachments/assets/cf2b7d7f-c594-4eb1-80f8-7b1e6e6baea7" />[](url)
This issue has 1 comment on GitHub. Read the full discussion on GitHub ↗