Skip to content

fix: allow Copilot reviewer bot to trigger review-responder and quality-gate#64

Merged
microsasa merged 1 commit intomainfrom
fix/allow-copilot-bot-activation
Mar 15, 2026
Merged

fix: allow Copilot reviewer bot to trigger review-responder and quality-gate#64
microsasa merged 1 commit intomainfrom
fix/allow-copilot-bot-activation

Conversation

@microsasa
Copy link
Owner

The pre_activation gate checks github.actor role (admin/maintainer/write). When Copilot reviewer submits a review, it's the actor but not a repo collaborator, so activation fails with action_required.

Fix: add bots: [copilot-pull-request-reviewer] to both workflows so the Copilot bot bypasses the role check.

…ty-gate

The pre_activation gate checks github.actor role (admin/maintainer/write).
When Copilot reviewer submits a review, it's the actor but not a repo
collaborator, so activation fails. Adding it to bots[] bypasses the
role check for this specific bot.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Copilot AI review requested due to automatic review settings March 15, 2026 05:47
Copy link

Copilot AI left a comment

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 workflow activation issue where the Copilot reviewer bot (copilot-pull-request-reviewer) could not trigger the review-responder and quality-gate gh-aw workflows because the bot isn't a repo collaborator with admin/maintainer/write role, causing the pre-activation gate to fail.

Changes:

  • Added bots: [copilot-pull-request-reviewer] to the frontmatter of both review-responder.md and quality-gate.md to bypass the role check for the Copilot bot.
  • Updated the corresponding .lock.yml files with new frontmatter hashes reflecting the config change.

Reviewed changes

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

File Description
.github/workflows/review-responder.md Added bots allowlist for Copilot reviewer bot
.github/workflows/quality-gate.md Added bots allowlist for Copilot reviewer bot
.github/workflows/review-responder.lock.yml Updated frontmatter hash to match new config
.github/workflows/quality-gate.lock.yml Updated frontmatter hash to match new config

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Copy link

Copilot AI left a comment

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 an activation issue where the Copilot reviewer bot (copilot-pull-request-reviewer) couldn't trigger the review-responder and quality-gate gh-aw workflows because the bot isn't a repo collaborator and fails the pre_activation role check. Adding bots: [copilot-pull-request-reviewer] to the workflow frontmatter allows the bot to bypass that check.

Changes:

  • Added bots: [copilot-pull-request-reviewer] to the frontmatter of review-responder.md and quality-gate.md
  • Updated the corresponding .lock.yml files with new frontmatter hashes

Reviewed changes

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

File Description
.github/workflows/review-responder.md Added bots allowlist for the Copilot reviewer bot
.github/workflows/quality-gate.md Added bots allowlist for the Copilot reviewer bot
.github/workflows/review-responder.lock.yml Updated frontmatter hash to reflect the .md change
.github/workflows/quality-gate.lock.yml Updated frontmatter hash to reflect the .md change

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

@microsasa microsasa merged commit c26a991 into main Mar 15, 2026
13 checks passed
@microsasa microsasa deleted the fix/allow-copilot-bot-activation branch March 15, 2026 05:51
microsasa pushed a commit that referenced this pull request Mar 15, 2026
check_membership.cjs has a bug where the error branch from a 404
(GitHub App actors are not users) exits before the bot allowlist
fallback is evaluated. This makes the bots: field ineffective.

Workaround: roles: all skips the permission check entirely so
check_membership.cjs is not included in pre_activation.

Previous attempts that didn't fix this:
- PR #64: bots: at top level (ignored by compiler)
- PR #65: bots: under on: (correct placement, but runtime bug)
- PR #72: added Copilot to bots list (correct actor, but bot check unreachable)

Tracked for removal when upstream is fixed: #74
Upstream bug: github/gh-aw#21098

Closes #75

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
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