Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Execute automerges using a PAT #162

Merged
merged 1 commit into from
Feb 22, 2022
Merged

Conversation

brrygrdn
Copy link
Contributor

@brrygrdn brrygrdn commented Feb 21, 2022

Ironically, this repository itself runs into the issue whereby API calls performed by dependabot[bot] inside Actions can't trigger downstream workflows so our auto merge commits don't trigger CI currently.

This PR follows our own advice on how to workaround the problem with merges. I'll update the README once I've verified this works as intended.

@brrygrdn brrygrdn merged commit 8e0cbe5 into main Feb 22, 2022
@brrygrdn brrygrdn deleted the brrygrdn/automerge-as-someone-else branch February 22, 2022 18:28
@mwaddell
Copy link
Contributor

@brrygrdn It looks like the PAT that's being used doesn't have the correct permissions set. See https://github.com/dependabot/fetch-metadata/runs/5359266073?check_suite_focus=true

gh pr merge --auto --merge "$PR_URL"
  shell: /usr/bin/bash -e {0}
  env:
    PR_URL: https://github.com/dependabot/fetch-metadata/pull/167
    GITHUB_TOKEN: ***
Message: Your token has not been granted the required scopes to execute this query. The 'enablePullRequestAutoMerge' field requires one of the following scopes: ['public_repo'], but your token has only been granted the: [''] scopes. Please modify your token's scopes at: https://github.com/settings/tokens., Locations: [{Line:1 Column:[7](https://github.com/dependabot/fetch-metadata/runs/5359266073?check_suite_focus=true#step:4:7)2}]
Error: Process completed with exit code 1.

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.

3 participants