Skip to content

Use supported Codex approval policy - #7864

Closed
jmwall wants to merge 1 commit into
omacom:quattrofrom
jmwall:fix/codex-app-server-approval-policy
Closed

jmwall wants to merge 1 commit into
omacom:quattrofrom
jmwall:fix/codex-app-server-approval-policy

Conversation

@jmwall

@jmwall jmwall commented Aug 23, 2026

Copy link
Copy Markdown
Contributor

Summary

  • launch the Codex app server with the supported never approval policy
  • verify the collector passes the expected sandbox, approval, and app-server arguments

Codex 0.149.0 rejects untrusted as an approval policy, causing initialization to fail and the Agents panel to show "Codex limits unavailable." Using never preserves the non-interactive collector behavior while matching the policies supported by the current CLI.

Testing

  • bash test/shell.d/agent-usage-codex-scanner-test.sh
  • real Codex 0.149.0 integration: omarchy-agent-usage-codex --limits-only returned the Pro tier and weekly limit data
  • ./test/all: 183 of 188 shell test files passed; the focused Codex test passed. Five unrelated environment/baseline failures remain: three require the companion omarchy-pkgs checkout, plus launch-about-test and network-qr-test.

Copilot AI balanced review requested due to automatic review settings August 23, 2026 07:31

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR fixes a compatibility break with Codex 0.149.0, which rejects untrusted as an approval policy, causing the app-server initialization to fail and the Agents panel to display "Codex limits unavailable." The collector (bin/omarchy-agent-usage-codex) launches the Codex app server in a read-only sandbox; switching the approval policy to the supported never value preserves the non-interactive collector behavior while remaining valid for the current CLI. A regression test asserts the exact argument list passed to the codex binary.

Changes:

  • Change the Codex app-server launch to use -a never instead of -a untrusted.
  • Add a test that captures the launched codex arguments (via a CODEX_ARGS_LOG stub hook) and asserts they equal -s read-only -a never app-server.

Tip

If you aren't ready for review, convert to a draft PR.
Click "Convert to draft" or run gh pr ready --undo.
Click "Ready for review" or run gh pr ready to reengage.

Reviewed changes

Copilot reviewed 1 out of 2 changed files in this pull request and generated no comments.

File Description
bin/omarchy-agent-usage-codex Replaces the unsupported untrusted approval policy with never when launching the Codex app server.
test/shell.d/agent-usage-codex-scanner-test.sh Adds an args-logging hook to the codex stub and asserts the collector launches with the expected sandbox/approval/app-server arguments.

💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.

@jmwall

jmwall commented Aug 23, 2026

Copy link
Copy Markdown
Contributor Author

OpenAI intentionally retired the untrusted approval policy in openai/codex#39630, released in Codex 0.149.0.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants