Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Branch Protection Not Recognized by Kodiak #893

Open
lodmfjord opened this issue Jun 13, 2024 · 2 comments · May be fixed by #894
Open

Branch Protection Not Recognized by Kodiak #893

lodmfjord opened this issue Jun 13, 2024 · 2 comments · May be fixed by #894
Labels
bug Something isn't working

Comments

@lodmfjord
Copy link

lodmfjord commented Jun 13, 2024

We have encountered an issue where Kodiak does not recognize the branch protection rules applied to our release/30.1.0 branch. Specifically, even though we have branch protection enabled, Kodiak is behaving as if there are no such rules in place.

Possible Cause:
This issue might be due to a limitation in the GitHub API. Our repository currently has 101 branches with this specific protection rule. Does the API only return the first 100 hits?

Workaround 1:
Creating a new protection rule for this branch works.

Workaround 2:
Deleting one branch worked - 100 branches are then branch protected by this rule.

Additional Context:
Link to a pull request

@lodmfjord lodmfjord added the bug Something isn't working label Jun 13, 2024
@chdsbd
Copy link
Owner

chdsbd commented Jun 14, 2024

This looks like a bug. We select the first 100 branch protection rules here:

branchProtectionRules(first: 100) {

@chdsbd
Copy link
Owner

chdsbd commented Jun 19, 2024

The issue in this query is the matchingRefs call:

matchingRefs(first: 100) {
nodes {
name
}
}

@chdsbd chdsbd linked a pull request Jun 20, 2024 that will close this issue
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants