Repository navigation
CM-73962: Stop sending explicit allow decisions from the Codex hook - #566
Merged
Altruistus merged 1 commit intoOct 5, 2026
Conversation
Older Codex runtimes reject PreToolUse permissionDecision "allow" as unsupported and report a failed hook on every permitted MCP call. Return an empty response for allow instead; deny responses are unchanged. Co-Authored-By: Claude Opus 5.5 <[email protected]>
omer-roth
approved these changes
Oct 5, 2026
Altruistus
deleted the
CM-73962-guardrail-hook-unsupported-permission-decision-allow-codex
branch
October 5, 2026 10:36
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
CM-73962: with AI Guardrails installed, Codex reported
PreToolUse hook returned unsupported permissionDecision:allowon every permitted MCP call.permissionDecision: "allow". The tool still runs, but each call logs a failed hook.Codex.build_hook_responsenow returns{}(no objection) for every allow, MCP calls and prompts alike. Codex prompts already returned{}.permissionDecision: "deny"pluspermissionDecisionReason, so violations still block and give a reason.Tests
{}.scan_commandtests for permitted and blocked Codex MCP calls.pytest tests/cli/commands/ai_guardrails: 356 passed.Note
Codex's docs say
permissionDecision: "ask"is still unsupported. When the policy returns ask, Codex logs the hook error and runs the tool anyway. This PR leaves ask unchanged until Codex supports it.🤖 Generated with Claude Code