-
Notifications
You must be signed in to change notification settings - Fork 719
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
Update linter #2725
Update linter #2725
Conversation
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
.golangci.yml
Outdated
@@ -19,6 +19,7 @@ linters: | |||
- scopelint | |||
- whitespace # added in 1.19 | |||
- wsl # added in 1.20 | |||
- gomnd # added in 1.23 |
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.
Nit: it would be nice to maintain the sorted order in this list
.golangci.yml
Outdated
- linters: | ||
- stylecheck | ||
text: 'ST1016: methods on the same type should have the same receiver name.*"in".*' | ||
- path: cmd/manager/main\.go |
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.
Again, this list was roughly sorted by path. No big deal 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.
Ah I didn't realize for either of them, fixing
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
jenkins test this please |
I actually changed this to the next to latest version of golangci-lint because it is OOMing jenkins. Already open issue here: And example test run failure of previous version of this PR with 1.24.0: |
jenkins test this please |
jenkins test this please |
I ran into a bug when troubleshooting the linter failure in #2724 that is resolved in newer golangci-lint versions (a lot of discussion in golangci/golangci-lint#827).
Fixes a bunch of linter warnings: