fix(lint): clear develop golangci-lint debt - #4237
Merged
Merged
Conversation
…staticcheck/unparam/ineffassign)
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Clears the remaining golangci-lint findings on
developso CI lint goes green: errcheck, gosec (G404), misspell, staticcheck (SA1019/SA4006/SA4023), unparam, and ineffassign.Notable fixes:
pk.Set/srv.Setin a disc test (check-blank enabled).//nolint:gosecon non-crypto shuffles used for peer/service/collection ordering (load distribution, not security-sensitive).marshalled->marshaledin CXO-publisher comments.http.Transport.Dial->DialContextviaproxy.ContextDialer; drop the deprecated no-opsvcmode.Config.DisableDHTfield.err != nilcomparisons on functions that only ever return a non-nil error (blockingServe/accept loops, theensureLoginChainstub).entry.String()error; drop a deadj--.encodeServicesBatch/encodeClientsBatchand update all callers; justified//nolint:unparamon a test closure whose signature is required byregistry.IterateFunc.Verified:
golangci-lint run ./...reports 0 issues,go build .succeeds, andgo testpasses for every package whose non-test code changed.Developed with AI assistance (Claude).