Does workflow `on: pull_request, types: [opened]` only run when PR is mergeable?


Yesterday I was trying to run a workflow on: pull_request with types: [opened, reopened].

I opened, closed, and re-opened the PR containing the workflow yaml several times and no workflow run was triggered. This PR was in a not-automatically-mergeable state.

Then I rebased the PR branch onto master, so that the PR was now automatically mergeable, and suddenly opening/closing/re-opening started to trigger the workflows.

So I’m wondering, is it expected or specified that on: pull_request workflows only run if the PR is mergeable? Or am I mistaken and something else is going on?


Hi @R2ZER0,

Glad to see you in Github Community Forum!

‘not-automatically-mergeable’ state means there’re some conflicts existing in the pull request.
There’s a limitation that workflow is not triggered for ‘pull_request’ event if conflicts exist, you have to resolve it firstly, via web editor or command line tool on local machine.
Rebase resolved the conflict, so the workflow is triggered.

Hope it’s clear and helpful!


Thanks for clarifying!

Does this limitation apply to pull_request webhooks too, or just running workflows?

Hi @R2ZER0,

Checked on my side, the webhook will still send out the payload even when conflicts existing on pull request.