ci: use HAYSTACK_BOT_TOKEN for CLA draft gate#12044
Merged
Merged
Conversation
GITHUB_TOKEN cannot execute the convertPullRequestToDraft / markPullRequestReadyForReview GraphQL mutations (fails with "Resource not accessible by integration", seen on #12036: the PR got the comment, label, and reviewer removal, but was never converted to draft). These mutations require a user token, so use the existing bot PAT. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
|
The latest updates on your projects. Learn more about Vercel for GitHub. 1 Skipped Deployment
|
anakin87
approved these changes
Jul 17, 2026
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.
Related Issues
Proposed Changes:
The CLA draft gate on #12036 correctly posted the comment, removed the reviewer, and added the
cla-pendinglabel — but the PR was never converted to draft. The workflow run logs show why:The
convertPullRequestToDraft/markPullRequestReadyForReviewGraphQL mutations require a user token; GitHub App installation tokens likeGITHUB_TOKENcannot call them, regardless of the grantedpull-requests: writepermission. This switches the workflow tosecrets.HAYSTACK_BOT_TOKEN(already used byrelease.ymlandupdate-platform-components.yml), with no silent fallback toGITHUB_TOKENso a missing secret fails loudly instead of half-gating PRs again.Side effects, both intentional:
github-actions[bot].GITHUB_TOKENevents), theready_for_review/review_requestedevents emitted byrestore()now correctly trigger thelinked_issue_reviewworkflow after a contributor signs the CLA.How did you test it?
cla_draft_gaterun logs (runs 29559061351, 29542596075) and the state of fix: warm child Toolset before flattening in Toolset.add() #12036 (labeled + commented but not drafted).main, on the next PR the sweep gates.Notes for the reviewer
HAYSTACK_BOT_TOKENto be a classic PAT withreposcope (it creates branches/PRs inrelease.yml, so it should be).Checklist
🤖 Generated with Claude Code