mirror of
https://github.com/openai/codex.git
synced 2026-11-14 06:48:26 +00:00
Let extensions resolve approval reviews before Guardian (#38592)
## What changed - Give approval review contributors the first opportunity to resolve an action when automatic review is not required for the model. - Return an extension's decision directly and fall back to Guardian when no extension claims the review. - Update Guardian V2 to approve actions below its risk threshold through the review contributor API, and remove the extension approval-policy API. ## Testing - Verify that an extension approval bypasses both the Guardian model call and the user approval prompt. - Cover Guardian V2 review decisions for low-risk, high-risk, and disabled threads. GitOrigin-RevId: 5be56941143aff6f358b75b5f8101b7c047147ae
This commit is contained in:
1 parent
5bc8da6d78
commit
23094236ac
12 files changed
+174
-149
No files matched your search
@@ -833,9 +833,7 @@ async fn review_guardian_mcp_elicitation(
|
||||
request.server_name.as_str(),
|
||||
elicitation_connector_id(&request.elicitation),
|
||||
);
|
||||
if !crate::guardian::routes_approval_policy_to_guardian(approval_policy, approvals_reviewer)
|
||||
&& !session.extension_strict_auto_review_enabled().await
|
||||
{
|
||||
if !crate::guardian::routes_approval_policy_to_guardian(approval_policy, approvals_reviewer) {
|
||||
return Ok(None);
|
||||
}
|
||||
|
||||
|
||||
Reference in new issue
Block a user