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

Bump golangci-lint for 1.23 compatibility #1823

Open
wants to merge 6 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from 4 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@ repos:
exclude: ^(vendor)

- repo: https://github.com/golangci/golangci-lint
rev: v1.59.1
rev: v1.60.1
hooks:
- id: golangci-lint

Expand All @@ -61,4 +61,4 @@ repos:
name: executable-shell
entry: chmod +x
language: system
types: [shell]
types: [shell]
2 changes: 1 addition & 1 deletion Taskfile.yml
Original file line number Diff line number Diff line change
Expand Up @@ -194,4 +194,4 @@ tasks:
install-golangci-lint:
internal: true
cmds:
- go install github.com/golangci/golangci-lint/cmd/golangci-lint@v1.59.1
- go install github.com/golangci/golangci-lint/cmd/golangci-lint@v1.60.1
2 changes: 2 additions & 0 deletions internal/integration/unified/event_verification.go
Original file line number Diff line number Diff line change
Expand Up @@ -302,6 +302,7 @@ func verifyCommandEvents(ctx context.Context, client *clientEntity, expectedEven
return nil
}

//nolint:govet
func verifyCMAPEvents(client *clientEntity, expectedEvents *expectedEvents) error {
pooled := client.poolEvents()
if len(expectedEvents.CMAPEvents) == 0 && len(pooled) != 0 {
Expand Down Expand Up @@ -491,6 +492,7 @@ func getNextTopologyDescriptionChangedEvent(
return events[0], events[:1], nil
}

//nolint:govet
func verifySDAMEvents(client *clientEntity, expectedEvents *expectedEvents) error {
var (
changed = client.serverDescriptionChanged
Expand Down
4 changes: 1 addition & 3 deletions mongo/client.go
Original file line number Diff line number Diff line change
Expand Up @@ -909,9 +909,7 @@ func newLogger(opts options.Lister[options.LoggerOptions]) (*logger.Logger, erro

// If there are no component-level options and the environment does not
// contain component variables, then do nothing.
if (args.ComponentLevels == nil || len(args.ComponentLevels) == 0) &&
!logger.EnvHasComponentVariables() {

if len(args.ComponentLevels) == 0 && !logger.EnvHasComponentVariables() {
return nil, nil
}

Expand Down
Loading