fix(codex): drop safe-yolo from Codex permission modes (#2183)

* fix(codex): drop safe-yolo from Codex permission modes

Every Codex session runs on the native shared runtime (runCodex is
runSharedCodex), which rejects safe-yolo. The mode stayed in
CODEX_PERMISSION_MODES and six filters hid it again in the web picker,
composer, hub permission-mode route, hapi set-mode and both native
apps. API callers that validate against the flavor catalog (e.g. a
spawn with permissionMode: 'safe-yolo') still passed it through and
only failed inside the runner.

Remove it from the Codex catalog (shared, iOS, Android, fixture) and
delete the filters. autoReview is the native replacement. Safe Yolo
stays for Gemini, Kimi and Copilot.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

* test(ios): Codex option list now has four modes

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

---------

Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
SSU-WEI HUANG
2026-10-28 12:12:55 +08:00
committed by GitHub
co-authored by Claude Opus 5.5
parent fe2fbb881d
commit ffd950a220
41 changed files with 44 additions and 161 deletions
+2 -3
View File
@@ -119,9 +119,8 @@ endpoints/tokens never go into HAPI session metadata or SSE.
- Cold resume accepts root threads only. To revisit a child agent, resume its
parent HAPI session; HAPI does not independently start a child execution.
- HAPI's legacy `safe-yolo` auto-approval policy is not a native Codex mode;
shared sessions reject it instead of silently weakening or misreporting it.
Use `default`, `read-only`, `autoReview`, or `yolo`. `autoReview` keeps the
- Codex permission modes are `default`, `read-only`, `autoReview`, and
`yolo`; HAPI's `safe-yolo` is not a native Codex mode. `autoReview` keeps the
workspace-write sandbox and routes escalations to Codex's native auto-review
(`approvals_reviewer = "auto_review"`, same as `--approve-for-me`).
- Web-created new/fork roots preserve the standard native sandbox restrictions.