Codex prompts per-file permission when worktree differs from opened folder
What version of the Codex App are you using (From “About Codex” dialog)?
26.228.1430 (760)
What subscription do you have?
Pro
What platform is your computer?
Darwin 25.3.0 arm64 arm
What issue are you seeing?
Title: Worktree mismatch causes per-file permission prompts and breaks thread continuity
Description:
When Codex creates a worktree that doesn't match the currently opened folder, it attempts to edit files outside the sandbox. This results in a permission prompt for every single file edit.
Switching to the correct folder to resolve this isn't a viable workaround either — doing so breaks the current thread, and there's no way to move or resume it in the new context.
I understand this is expected to an extent, but it renders the models ability to switch worktrees as needed significantly less useful.
What steps can reproduce the bug?
- Open a folder in Codex
- Let Codex create a worktree that differs from the opened folder
- Observe per-file permission prompts for each edit
- Attempt to switch to the worktree folder — thread is lost and cannot be resumed
What is the expected behavior?
Target behaviour:
If the thread switches worktrees, then Codex can mark the chat as a new worktree, similar to starting a new thread on a new worktree... this way it's consistent and you don't end up with a mismatch between the tread default and worktree codex is working on.
OR
A dropdown menu next to the branch selector (at the bottom of the UI) that allows switching the active worktree without losing the current thread. This ties into the previously suggested feature for worktree switching.
Additional information
I understand this is expected to an extent, but it renders the models ability to switch worktrees as needed significantly less useful.
Overall, I believe the permissions needs a deeper look and plan so it's managed more seamlessly, especially on the Mac app.