Skip to content

Required status checks and merge queues #424273

@wolfgangwalther

Description

@wolfgangwalther

(only relevant for committers)

We have recently enabled required status checks for the Nixpkgs repo and merge queues for the master branch and currently maintained "release" branches (i.e. release-25.05).

For now, every committer is able to bypass these checks and merge anyway (see below). Initially, this will be needed to merge a PR where CI last ran before ~ June, 18th.

Please report any other cases where you needed to bypass the rules for merge in NixOS/org#130!

This will help us make sure we're not blocking any valid use-cases when we eventually disallow bypassing these checks entirely.

Note: Only the GitHub Actions CI is required for merge. You still need to check ofborg results and/or confirm everything builds manually.


Additionally, here's a quick rundown of how to work with the required status checks in more detail:

  1. There is a new item in the PR's check list now, it looks like this:

    Image

    Until this check is completed, merging the PR is blocked.

  2. Once all other jobs passed, this check will become "successful":

    Image

    The PR is now merge-able.

  3. PRs targeting a branch using merge queues will usually look like this:

    Image

    PRs targeting other branches will look like this when merge is blocked:

    Image

    If you need to merge the PR despite failing CI, you'll need to check the box.

  4. PRs targeting a branch using merge queues will join the queue, which will be merged once additional checks have completed:

    Image

    You can monitor the queue by clicking the merge queue link at the bottom of the PR, or next to the targeted branch on the repo's Branches tab.

    You can monitor the workflows running against the queue by going to the Actions tab and selecting Merge Group.

  5. Selecting "Merge without waiting for requirements to be met" on a PR targeting master will skip the merge queue entirely. That's because the merge queue is one of the "requirements" that is being bypassed.

    Bypassing the merge queue will cause the PR to merge directly into master. Any PRs already in the queue will then restart their CI and take longer to merge.

  6. Older PRs, which last ran CI before the merge of workflows/{pr,push}: init #415006, will not run the required check; it will remain "expected" indefinitely. In this case, you have multiple options:

    • Re-run CI by closing / opening the PR.
    • Re-run CI by (force) pushing the branch.
    • Merge despite the missing check by checking the box (not recommended).
  7. If you need to merge a PR with failing CI for any other reasons than the PR being old, please report this in nixpkgs branch protection rules: require status checks to pass org#130.

  8. Important note for those merging PRs from the command line via git: Except on the master branch, where Merge Queues are required, there is no protection for git merges so long as your account can bypass required status checks. Merging from the CLI via git push will always bypass the status checks. However, merging via gh pr merge supports those checks, according to the documentation.

Metadata

Metadata

Assignees

No one assigned

    Labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions