-
Notifications
You must be signed in to change notification settings - Fork 4k
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
Chore: fixed lints errors #7542
Conversation
Signed-off-by: Omer Aplatony <omerap12@gmail.com>
Signed-off-by: Omer Aplatony <omerap12@gmail.com>
@@ -642,7 +642,7 @@ func TestEvictEmitEvent(t *testing.T) { | |||
mockRecorder.On("Event", mock.Anything, apiv1.EventTypeNormal, "EvictedByVPA", mock.Anything).Return() | |||
mockRecorder.On("Event", mock.Anything, apiv1.EventTypeNormal, "EvictedPod", mock.Anything).Return() | |||
|
|||
eviction.Evict(p.pod, testCase.vpa, mockRecorder) | |||
_ = eviction.Evict(p.pod, testCase.vpa, mockRecorder) |
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.
@adrianmoisey error check here caused a failure (https://github.com/kubernetes/autoscaler/actions/runs/12082981510/job/33695187736) so I ignore that for now.
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.
Oh interesting. Based on this test, I think that error is expected, since the pod can't be evicted.
Would you be able to change the test to include testing if an error is expected or not?
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.
sure. In this PR?
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'm not too fussed, your choice
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 |
Thanks for the PR!
Yeah, absolutely! I think this is the only way to keep these errors out of the codebase. /approve |
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: omerap12, voelzmo 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 |
Ill raise a PR then :) |
HolderIdentity: pointer.String(c.holderIdentity), | ||
LeaseDurationSeconds: pointer.Int32(c.leaseDurationSeconds), | ||
HolderIdentity: ptr.To(c.holderIdentity), | ||
|
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.
Why you introduce a new no-op empty line?
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.
by mistake, Ill raise a PR to fix thanks
What type of PR is this?
/kind cleanup
What this PR does / why we need it:
This PR addresses several linting issues identified in the codebase, as follows:
This PR fixes those issues.
Which issue(s) this PR fixes:
Fixes #
Special notes for your reviewer:
Should we add
golangci-lint run
to our GitHub Actions pipeline? It seems like a helpful way to catch these issues early.Does this PR introduce a user-facing change?
Additional documentation e.g., KEPs (Kubernetes Enhancement Proposals), usage docs, etc.: