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

Update to golangci-lint 1.51.0 #1824

Merged
merged 18 commits into from
Feb 6, 2023
Merged

Update to golangci-lint 1.51.0 #1824

merged 18 commits into from
Feb 6, 2023

Conversation

mtrmac
Copy link
Collaborator

@mtrmac mtrmac commented Feb 2, 2023

This is required for support of Go 1.20.

Also avoid a call to math/rand.Read, which is deprecated in Go 1.20.


Then, manually enable all linters, and fix up things that seem either relevant, or easier to fix than to check again.

@mtrmac mtrmac force-pushed the golangci-lint branch 4 times, most recently from 207e216 to 261c33b Compare February 3, 2023 17:32
Copy link
Member

@vrothberg vrothberg left a comment

Choose a reason for hiding this comment

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

LGTM
Needs a rebase

mtrmac added 18 commits February 6, 2023 21:15
This is required for support of Go 1.20.

Also avoid a call to math/rand.Read, which is deprecated in Go 1.20.

Signed-off-by: Miloslav Trmač <mitr@redhat.com>
golangci-lint linter: bodyclose

Signed-off-by: Miloslav Trmač <mitr@redhat.com>
golangci-lint linter: dupword

Signed-off-by: Miloslav Trmač <mitr@redhat.com>
golangci-lint linter: errorlint

Signed-off-by: Miloslav Trmač <mitr@redhat.com>
golangci-lint linter: forbidigo

Signed-off-by: Miloslav Trmač <mitr@redhat.com>
golangci-lint linter: gci

Signed-off-by: Miloslav Trmač <mitr@redhat.com>
golangci-lint linter: gocritic

Signed-off-by: Miloslav Trmač <mitr@redhat.com>
golangci-lint linter: gocritic

Signed-off-by: Miloslav Trmač <mitr@redhat.com>
golangci-lint linter: gocritic

Don't use the "linter control" format without a leading space
Use a correct Deprecated: comment

Signed-off-by: Miloslav Trmač <mitr@redhat.com>
golangci-lint linter: godot

Signed-off-by: Miloslav Trmač <mitr@redhat.com>
golangci-lint linter: golint

Signed-off-by: Miloslav Trmač <mitr@redhat.com>
golangci-lint linter: golint

Signed-off-by: Miloslav Trmač <mitr@redhat.com>
golangci-lint linter: golint

Signed-off-by: Miloslav Trmač <mitr@redhat.com>
golangci-lint linter: golint

Signed-off-by: Miloslav Trmač <mitr@redhat.com>
golangci-lint linter: prealloc

Signed-off-by: Miloslav Trmač <mitr@redhat.com>
golangci-lint linter: unparam

Signed-off-by: Miloslav Trmač <mitr@redhat.com>
golangci-lint linter: unparam

Signed-off-by: Miloslav Trmač <mitr@redhat.com>
golangci-lint linter: whitespace

Signed-off-by: Miloslav Trmač <mitr@redhat.com>
@mtrmac
Copy link
Collaborator Author

mtrmac commented Feb 6, 2023

Rebased. Merging immediately so that make with Go 1.20 installed works.

Apologies for the churn.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants