We cancel in-progress workflows in a pull request when a new commit is added. This is desirable.
However, we also cancel in-progress workflows after we merge a pull request to the main branch. This is not desirable because not all pull requests run all checks. A documentation pull request will not run tests, etc. As such, when a documentation pull request is merged to main after a code change to main, it should not cancel the tests that run against main. Example of that happening:
This pull request changes the concurrency configuration so only pull request workflows are canceled. Each merge to main will run its workflow to completion (github.run_id is unique, guaranteeing a unique group name on merge to main).
We cancel in-progress workflows in a pull request when a new commit is added. This is desirable.
However, we also cancel in-progress workflows after we merge a pull request to the
main
branch. This is not desirable because not all pull requests run all checks. A documentation pull request will not run tests, etc. As such, when a documentation pull request is merged tomain
after a code change tomain
, it should not cancel the tests that run againstmain
. Example of that happening:This pull request changes the concurrency configuration so only pull request workflows are canceled. Each merge to
main
will run its workflow to completion (github.run_id
is unique, guaranteeing a unique group name on merge tomain
).