[GODRIVER-2782] Fix "revive" v1.3.1 linter failures Created: 22/Mar/23  Updated: 03/Apr/23  Resolved: 03/Apr/23

Status: Closed
Project: Go Driver
Component/s: None
Affects Version/s: None
Fix Version/s: None

Type: Task Priority: Unknown
Reporter: Matt Dale Assignee: Matt Dale
Resolution: Done Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Issue Links:
Duplicate
is duplicated by GODRIVER-2781 Resolve linting failures resulting fr... Closed
Related
related to GODRIVER-2784 Re-enable "paralleltest" linter Closed
Documentation Changes Summary:

1. What would you like to communicate to the user about this feature?
2. Would you like the user to see examples of the syntax and/or executable code and its output?
3. Which versions of the driver/connector does this apply to?


 Description   

The golangci-lint tool recently upgraded revive from v1.3.0 to v1.3.1 (see PR), which causes a bunch of additional "unused-parameter" errors.

E.g. error:

bson/bsoncodec/default_value_decoders.go:191:51: unused-parameter: parameter 'dctx' seems to be unused, consider removing or renaming it as _ (revive)
func (dvd DefaultValueDecoders) booleanDecodeType(dctx DecodeContext, vr bsonrw.ValueReader, t reflect.Type) (reflect.Value, error) {

Definition of done:

  • Resolve all new revive v1.3.1 lint errors


 Comments   
Comment by Githook User [ 03/Apr/23 ]

Author:

{'name': 'Matt Dale', 'email': '9760375+matthewdale@users.noreply.github.com', 'username': 'matthewdale'}

Message: GODRIVER-2782 Resolve updated revive v1.3.1 lint errors. (#1208)
Branch: master
https://github.com/mongodb/mongo-go-driver/commit/705e61ab963966f25acca9eabd7513f11f0b2fe0

Generated at Thu Feb 08 08:39:21 UTC 2024 using Jira 9.7.1#970001-sha1:2222b88b221c4928ef0de3161136cc90c8356a66.