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
go vet ./... fails on macOS because ~/Library/Caches is not allowed to be used in the codex sandbox #3720
The command should fail and the model sometimes sets the 'GOCACHE` env var to a directory in the current directory or just tells you to run the command yourself.
changed the title [-]`go vet ./...` fails on macOS because `~/Library/Caches` is not allowed to be used[/-][+]`go vet ./...` fails on macOS because `~/Library/Caches` is not allowed to be used in the codex sandbox[/+]on Sep 16, 2025
I actually don't really mind this sandbox limitation. I actually think that it is good that it works like this, but it would be nice if it at least showed some sort of message to the user that the sandbox prevent a command from running because it tried to access a resource outside the sandbox instead of just showing that red dot/the command just failing.
Because in this case it could be a genuine error or just the sandbox preventing it. Codex sometimes just doesn't tell you.
# Extra settings that only apply when `sandbox = "workspace-write"`.
[sandbox_workspace_write]
# By default, the cwd for the Codex session will be writable as well as $TMPDIR
# (if set) and /tmp (if it exists). Setting the respective options to `true`
# will override those defaults.
exclude_tmpdir_env_var = false
exclude_slash_tmp = false
# Optional list of _additional_ writable roots beyond $TMPDIR and /tmp.
writable_roots = ["/Users/xxxxxxxx/Library/Caches"]
does this work for you? this is found in codex's doc, however it doesn't seem to be working for me... although the purpose of this config looks exactly the same as what we want
Yes that works, but everyone would have to do this when they work with go. I feel like that's not really user friendly, especially because this is pretty similar to /tmp.
Activity
[-]`go vet ./...` fails on macOS because `~/Library/Caches` is not allowed to be used[/-][+]`go vet ./...` fails on macOS because `~/Library/Caches` is not allowed to be used in the codex sandbox[/+]ZerGo0 commentedon Sep 16, 2025
I actually don't really mind this sandbox limitation. I actually think that it is good that it works like this, but it would be nice if it at least showed some sort of message to the user that the sandbox prevent a command from running because it tried to access a resource outside the sandbox instead of just showing that red dot/the command just failing.
Because in this case it could be a genuine error or just the sandbox preventing it. Codex sometimes just doesn't tell you.
Meowzz95 commentedon Oct 3, 2025
does this work for you? this is found in codex's doc, however it doesn't seem to be working for me... although the purpose of this config looks exactly the same as what we want
Meowzz95 commentedon Oct 3, 2025
Oh I just figured that out. We must set
at the TOP of the config.toml file (I misplaced it above my sandbox_workspace_write section and it didn't work)
now go test works!
ZerGo0 commentedon Oct 3, 2025
Yes that works, but everyone would have to do this when they work with go. I feel like that's not really user friendly, especially because this is pretty similar to /tmp.