Skip to content

Conversation

@wolfgangwalther
Copy link
Contributor

Dependabot can't create branches anymore to update github-actions: https://github.com/NixOS/nixpkgs/network/updates

Broke in #132.

I hope this fixes it, but the double star glob was confusing the last time, so let's see...

@wolfgangwalther wolfgangwalther requested a review from a team as a code owner July 22, 2025 11:01
Dependabot can't create branches anymore to update github-actions.
@infinisil infinisil force-pushed the nixpkgs-rulesets-create-dependabot-branches branch from b228fbe to df53f27 Compare July 22, 2025 11:06
Copy link
Member

@infinisil infinisil left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM, applied!

@infinisil infinisil enabled auto-merge July 22, 2025 11:07
@infinisil infinisil merged commit 032bc97 into NixOS:main Jul 22, 2025
2 checks passed
@wolfgangwalther wolfgangwalther deleted the nixpkgs-rulesets-create-dependabot-branches branch July 22, 2025 11:09
@wolfgangwalther
Copy link
Contributor Author

Hm, that didn't seem to work, yet: https://github.com/NixOS/nixpkgs/network/updates/14302654/jobs

Tried twice, both still failed with that "can't create branch" error.

@wolfgangwalther
Copy link
Contributor Author

Older dependabot PRs are here: https://github.com/NixOS/nixpkgs/pulls?q=is%3Apr%20author%3Aapp%2Fdependabot%20is%3Aclosed

The branch pattern is certainly dependabot/.... But it has multiple /. Apparently ** doesn't match multiple of these, because:

% gh api /repos/NixOS/nixpkgs/rules/branches/dependabot/test
[]

(that's good)

% gh api /repos/NixOS/nixpkgs/rules/branches/dependabot/test/test
[
  {
    "type": "creation",
    "ruleset_source_type": "Repository",
    "ruleset_source": "NixOS/nixpkgs",
    "ruleset_id": 6008904
  }
]

That's bad.

"refs/heads/revert-*",
"refs/heads/revert-*/**"
"refs/heads/revert-*/**",
"refs/heads/dependabot/**"
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Aha, maybe I misread the docs, they say:

You can include any number of slashes after qa with qa/**/*

So maybe:

refs/heads/dependabot/**/*

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I assume we need the same for the revert branch, so:

refs/heads/revert-*/**/*

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@infinisil should I create a new PR about this or did you keep track of this?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants