fix(review-agent-governance): make target_branch optional with has-gu… · codehornets/agents-claude-code@8ddb737 · GitHub
Skip to content

Commit 8ddb737

Browse files
committed
fix(review-agent-governance): make target_branch optional with has-guard (wshobson#598)
Non-git Bash actions (gh pr comment, etc.) don't carry target_branch, so requiring it in the schema would make every such request error at runtime. Mark it optional and guard rule 3 with `context has target_branch` so the git-push-to-protected-branch forbid only applies when a branch is supplied. cedar validate stays clean (optional attr accessed under a has-guard).
1 parent bdf6e19 commit 8ddb737

2 files changed

Lines changed: 2 additions & 1 deletion

File tree

‎plugins/review-agent-governance/policies/review-agent-governance.cedar‎

Lines changed: 1 addition & 0 deletions

‎plugins/review-agent-governance/policies/review-agent-governance.cedarschema‎

Lines changed: 1 addition & 1 deletion

0 commit comments

Comments
 (0)