-
Notifications
You must be signed in to change notification settings - Fork 1.4k
⚠️ Change type of int32 fields with valid zero value to *int32 #12424
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
⚠️ Change type of int32 fields with valid zero value to *int32 #12424
Conversation
Ready for review, but we might want to merge another PR first |
/test pull-cluster-api-e2e-main |
fc8c21e
to
667d9d0
Compare
/test pull-cluster-api-e2e-main |
/assign @JoelSpeed @fabriziopandini |
/test pull-cluster-api-e2e-main |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
/lgtm
/approve
@@ -758,7 +758,7 @@ type KubeadmControlPlaneV1Beta1DeprecatedStatus struct { | |||
// Deprecated: This field is deprecated and is going to be removed when support for v1beta1 will be dropped. Please see https://github.com/kubernetes-sigs/cluster-api/blob/main/docs/proposals/20240916-improve-status-in-CAPI-resources.md for more details. | |||
// | |||
// +optional | |||
UnavailableReplicas int32 `json:"unavailableReplicas"` | |||
UnavailableReplicas int32 `json:"unavailableReplicas"` //nolint:kubeapilinter // field will be removed when v1beta1 is removed |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Just a note, when we are doing noline:kubeapilinter
in the future, it's better to use the regex based excludes so that we can exclude single messages rather than entire fields from being checked across all rules.
In this case since it's going away, this is fine though
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Good point, but I thought there is less harm in a local nolint vs an exclude which might match other fields accidentally in this case (we have some of these fields with the same name elsewhere)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think you can scope at least to package level and field name, so provided there aren't fields with duplicated names (which there probably are for us) then that would work. Would have to double check if we can scope more succinctly
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think in some cases it's the same CRD
LGTM label has been added. Git tree hash: f84766586984b5063c0a2c4cce3b168c81ac949e
|
/hold For Fabrizio's review |
/test pull-cluster-api-e2e-main |
eab51b8
to
98e2300
Compare
/lgtm |
LGTM label has been added. Git tree hash: 9269eb305097dd82675daa7408967d7b89bc11c7
|
/test pull-cluster-api-e2e-main |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Just a few nits, great job!
98e2300
to
7393050
Compare
Signed-off-by: Stefan Büringer [email protected]
7393050
to
bf8a7e2
Compare
@sbueringer: The following test failed, say
Full PR test history. Your PR dashboard. Please help us cut down on flakes by linking to an open issue when you hit one in your PR. Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes-sigs/prow repository. I understand the commands that are listed here. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
/lgtm
/approve
LGTM label has been added. Git tree hash: b9faddcbe74831a58a12d452d99f9fc803ecc2a3
|
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: fabriziopandini, JoelSpeed The full list of commands accepted by this bot can be found here. The pull request process is described here
Needs approval from an approver in each of these files:
Approvers can indicate their approval by writing |
/hold cancel |
Signed-off-by: Stefan Büringer [email protected]
What this PR does / why we need it:
Which issue(s) this PR fixes (optional, in
fixes #<issue number>(, fixes #<issue_number>, ...)
format, will close the issue(s) when PR gets merged):Part of #10852