No available status checks for branch protections #167194
Replies: 5 comments
|
Totally understand the confusion In your case, main and they've reported their status directly to GitHub Actions (or another CI provider). If those checks only ran on the PR before merging and didn’t run again after it was merged into main, they won’t show up as selectable. A quick fix is to manually trigger a workflow on the main branch (like pushing a small commit or re-running the workflow from Actions), and once the check appears there and passes, it should become available in the branch protection settings. Hope that helps! |
|
GitHub only populates that dropdown with checks that have actually run on the branch itself (i.e. via a push event to main). If your Action workflows only fire on pull_request they won’t show up there, same goes for apps that never report a “check_suite” on a push. Add a push: branches: [main] trigger, refresh the branch‑protection page, and the check names should finally appear so you can require them. |
|
I'm trying the same. I want to create an Org Wide Release branch Ruleset to require a sucessful build. in Bitbucket this was: "Check the last commit for at least 1 successful build, no failed builds, and no in progress builds" - It seems like chicken / eggs though, there is nothing in the Checks list. We are migrating to Github and I don't see an equivalant way to require a build check. No way to say: "for a specific branch filter / Check the last commit for at least 1 successful build, no failed builds, and no in progress builds?" The branch doesn't exist, the repo doesn't yet exist. Just trying to configure rulesets.. |
|
You can’t select any required checks because GitHub only shows checks that have run on the protected branch ( To fix it:
|
|
I think this is fixed for the repo level rule sets. I was not seeing my checks for a repo that never ran them in main when looking at them at the organization level. But when I tried adding the required check at the repo level, it populated the list with all the checks that had run in my PR. |
Uh oh!
There was an error while loading. Please reload this page.
Select Topic Area
Question
Body
I am trying to set up required status checks in the "Require status checks to pass before merging" section of my branch protection rule for my "main" branch. However there are no checks available to add.
Most of what I see online suggests that this would be caused by not having recent (within 7 days) checks pass. I don't think this would be the case as I see 3 checks that passed from a GitHub action and 1 additional check from a Sonarqube app in the "checks" tab of a PR I merged into main about an hour ago.
Why can't select any required checks?
All reactions