Mergify Update: Not working on PR's from forks where workflows have been updated in main
When opening a PR from a fork and attempting @Mergifyio update on the PR we get the following error if any workflows have been added or updated in main since the fork was created:
update
❌ Mergify doesn't have permission to update
Details
For security reasons, Mergify can't update this pull request. Try updating locally.
GitHub response: refusing to allow a GitHub App to create or update workflow .github/workflows/<updated-workflow>.yaml without workflows permission
We've confirmed that the Mergify app has workflow permissions, this appears to be a similar issue to #5055 but we're still seeing it as of today.
Expected Behavior
The fork branch gets updated from main.
Actual Behavior
The fork branch is not updated.
Steps to Reproduce the Problem
- Create a fork from a repo
- Create a PR
- Update any workflow file on the main repo
- @Mergifyio update
The details say it all: Mergify cannot do that. For security reasons, it just can't and will never be able to update a PR from a fork. It's not Mergify's choice; it's the GitHub permission system that does not allow it to do that.
Did you try using the update button from GH instead https://docs.github.com/en/pull-requests/collaborating-with-pull-requests/proposing-changes-to-your-work-with-pull-requests/keeping-your-pull-request-in-sync-with-the-base-branch ?