Skip to content

fix!: Add ListOptions to ListDeploymentBranchPolicies and ListCustomDeploymentRuleIntegrations#3988

Merged
gmlewis merged 3 commits intogoogle:masterfrom
Not-Dhananjay-Mishra:repo
Feb 12, 2026
Merged

fix!: Add ListOptions to ListDeploymentBranchPolicies and ListCustomDeploymentRuleIntegrations#3988
gmlewis merged 3 commits intogoogle:masterfrom
Not-Dhananjay-Mishra:repo

Conversation

@Not-Dhananjay-Mishra
Copy link
Contributor

BREAKING CHANGE: RepositoriesService.ListDeploymentBranchPolicies and RepositoriesService.ListCustomDeploymentRuleIntegrations now accept one more parameter ListOptions

RepositoriesService.ListCustomDeploymentRuleIntegrations also support pagination acc to docs.
RepositoriesService.ListDeploymentBranchPolicies also support pagination acc to docs.

Updates: #3976

Copy link
Collaborator

@gmlewis gmlewis left a comment

Choose a reason for hiding this comment

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

Thank you, @Not-Dhananjay-Mishra!

@codecov
Copy link

codecov bot commented Feb 10, 2026

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 93.52%. Comparing base (71958fb) to head (2c99f61).
⚠️ Report is 3 commits behind head on master.

Additional details and impacted files
@@           Coverage Diff           @@
##           master    #3988   +/-   ##
=======================================
  Coverage   93.52%   93.52%           
=======================================
  Files         207      207           
  Lines       17590    17596    +6     
=======================================
+ Hits        16451    16457    +6     
  Misses        938      938           
  Partials      201      201           

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@gmlewis
Copy link
Collaborator

gmlewis commented Feb 10, 2026

And now I'm left wondering why new iterators weren't created by gen-iterators.go?

@gmlewis
Copy link
Collaborator

gmlewis commented Feb 10, 2026

And why didn't the CI/CD catch that the iterators had not been updated?

@Not-Dhananjay-Mishra
Copy link
Contributor Author

Not-Dhananjay-Mishra commented Feb 10, 2026

And now I'm left wondering why new iterators weren't created by gen-iterators.go?

Both of these functions return a struct not a array of struct. even when I add

var customTestJSON = map[string]string{
	"ListAllTopics":                                `{"names": []}`,
	"ListUserInstallations":                        `{"installations": []}`,
	"DeploymentBranchPolicyResponse":               `{"branch_policies": []}`,
	"ListCustomDeploymentRuleIntegrationsResponse": `{"available_custom_deployment_protection_rule_integrations": []}`,
}

and run go generate ./... iterator for them not generates

Edit : I don't think customTestJSON will work if function returns struct

@gmlewis
Copy link
Collaborator

gmlewis commented Feb 10, 2026

Edit : I don't think customTestJSON will work if function returns struct

Ah! OK, maybe it needs to support the return of a struct? Sounds like a feature request!

@Not-Dhananjay-Mishra - would you mind opening a new issue to add support to gen-iterators.go for methods that return structs if its method takes either ListOptions or ListCursorOptions, please?

@gmlewis gmlewis added NeedsReview PR is awaiting a review before merging. Breaking API Change PR will require a bump to the major version num in next release. Look here to see the change(s). labels Feb 10, 2026
Copy link
Collaborator

@gmlewis gmlewis left a comment

Choose a reason for hiding this comment

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

Excellent! Thank you, @Not-Dhananjay-Mishra!
LGTM.
Awaiting second LGTM+Approval from any other contributor to this repo before merging.

cc: @stevehipwell - @alexandear - @zyfy29

@gmlewis
Copy link
Collaborator

gmlewis commented Feb 11, 2026

@Not-Dhananjay-Mishra - it will be interesting to see how #3991 affects this PR.
Please let me know if you experience any problems when merging master into this PR.

@gmlewis gmlewis removed the NeedsReview PR is awaiting a review before merging. label Feb 12, 2026
@gmlewis
Copy link
Collaborator

gmlewis commented Feb 12, 2026

Thank you, @alexandear!
Merging.

@gmlewis gmlewis merged commit ab5ad47 into google:master Feb 12, 2026
8 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Breaking API Change PR will require a bump to the major version num in next release. Look here to see the change(s).

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants

Comments