codex - 💡(How to fix) Fix /permissions Full Access session-only confirmation persists approvals_reviewer to config.toml [1 comments, 2 participants]

Official PRs (…)
ON THIS PAGE

Recommended Tools

×6

Utilities matched from this issue’s tags and category — try them while you read without losing context.

GitHub issue graph ai analysis

Paste a GitHub issue URL. We fetch that issue, discover linked issues from bodies/comments/timeline, collect linked pull requests, and produce a structured English report.

The report is written in English Markdown for sharing and archival.

Helpful · Quick feedback

Loading…
GitHub stats
openai/codex#19297Fetched 2026-04-24 10:39:05
View on GitHub
Comments
1
Participants
2
Timeline
6
Reactions
0
Timeline (top)
labeled ×4closed ×1commented ×1

Root Cause

I could not open a PR because this repository currently limits pull request creation to collaborators.

Fix Action

Fix / Workaround

Patch

The patch adds a session-only UpdateApprovalsReviewerForSession event and uses it for /permissions preset selection. The existing persistent UpdateApprovalsReviewer event remains available for paths that intentionally write approvals_reviewer to config.toml.

Reason: the local shell used for preparing the patch does not currently have cargo, rustfmt, or just on PATH.

Code Example

/permissions -> Full Access -> Yes, continue anyway
RAW_BUFFERClick to expand / collapse

Bug

In Codex CLI 0.124.0, selecting:

/permissions -> Full Access -> Yes, continue anyway

is described as applying Full Access "for this session", but it also persists approvals_reviewer = "user" to config.toml.

Expected

The session-only confirmation should update the active session state only.

Actual

approvals_reviewer is written to config.toml, which can overwrite a persisted reviewer such as guardian_subagent.

Reproduction

  1. Start Codex with a non-Full Access permission state and a persisted reviewer, for example approvals_reviewer = "guardian_subagent".
  2. Open /permissions.
  3. Select Full Access.
  4. In the confirmation prompt, select Yes, continue anyway, whose description is Apply full access for this session.
  5. Inspect ~/.codex/config.toml.

Observed locally on codex-cli 0.124.0: the persisted config changed approvals_reviewer to user even though the prompt said the choice was session-scoped.

Patch

I prepared a minimal fix in my fork:

The patch adds a session-only UpdateApprovalsReviewerForSession event and uses it for /permissions preset selection. The existing persistent UpdateApprovalsReviewer event remains available for paths that intentionally write approvals_reviewer to config.toml.

I could not open a PR because this repository currently limits pull request creation to collaborators.

Local verification

  • git diff --check passed

Not run locally:

  • cargo fmt
  • cargo test -p codex-tui permissions_full_access_history_cell_emitted_only_after_confirmation

Reason: the local shell used for preparing the patch does not currently have cargo, rustfmt, or just on PATH.

extent analysis

TL;DR

The issue can be fixed by applying a patch that introduces a session-only UpdateApprovalsReviewerForSession event for the /permissions preset selection, preventing the overwrite of the persisted approvals_reviewer in config.toml.

Guidance

  • Review the provided patch in the forked repository to understand the proposed fix.
  • Verify the patch by running cargo fmt and cargo test -p codex-tui permissions_full_access_history_cell_emitted_only_after_confirmation to ensure it does not introduce any formatting or testing issues.
  • Consider reaching out to the repository collaborators to discuss the patch and potentially open a pull request.
  • Before applying the patch, ensure that the local development environment has the necessary tools (cargo, rustfmt, just) installed and configured.

Example

No code snippet is provided as the issue already includes a link to the proposed patch.

Notes

The provided patch seems to address the issue by introducing a session-only event, but it has not been thoroughly verified due to the lack of necessary tools in the local environment.

Recommendation

Apply the workaround by using the patched version of the code, as it seems to fix the issue without introducing any obvious problems, and the original behavior is not intended.

Vote matrix · Quick signals

Works
Did the solution work? Tap to confirm.
Easy Fix
Was it a quick fix?
Time Saver
Did it save you time?
Blocking
Was it severely blocking?
Common Issue
Are others likely hitting this too?
Flaky / Intermittent
Is it intermittent?
Verified / Reproducible
Can you reproduce it reliably?
Loading…

Still need to ship something?

×6

Another batch ranked right after the header list — different links, same matching logic.

Back to top recommendations

TRENDING

codex - 💡(How to fix) Fix /permissions Full Access session-only confirmation persists approvals_reviewer to config.toml [1 comments, 2 participants]