Debug: print copilot-review gate inputs#1592
Merged
Merged
Conversation
Prints draft, author_association, and event action on every PR to diagnose why the request-copilot-review gate is evaluating to false on maintainer PRs (e.g. #1589). Remove once the gate is fixed.
This was referenced May 11, 2026
brendancol
added a commit
that referenced
this pull request
May 11, 2026
The pull_request_target event payload reports author_association as CONTRIBUTOR for org members on same-repo branches (confirmed via the debug-event job added in #1592 and fired by #1593), so the previous gate filtered out every maintainer PR. Switch to head.repo.full_name == base.repo.full_name. Same-repo PRs require push access to the base repo, which is the maintainer signal we actually want. Fork PRs (where the maintainer cannot push to base) remain excluded. Also removes the now-unneeded debug-event job.
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
debug-eventjob to.github/workflows/copilot-review.ymlthat printsaction,draft,author_association,user.login, and head/base repo on everypull_request_targetevent.Why
The
request-copilot-reviewjob has been silently skipped on every PR since the workflow landed (e.g. #1589, plus the next maintainer PR after it). The REST view of those PRs showsdraft: falseandauthor_association: "MEMBER", which should satisfy the gate, so the event payload likely contains a different value at trigger time. The debug job will surface that value once any PR fires the workflow.Test plan
debug-eventjob logs and confirm whatassocactually is at event timeif:condition (or drop theauthor_associationgate) and remove the debug job