-
Notifications
You must be signed in to change notification settings - Fork 15
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
Org-wide linter fixes #1004
Merged
Merged
Org-wide linter fixes #1004
Conversation
This file contains 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
Argh, |
carpawell
requested review from
carpawell
and removed request for
carpawell
September 13, 2024 15:05
api/handler/put.go:132:4 predeclared variable min has same name as predeclared identifier api/handler/put.go:133:4 predeclared variable max has same name as predeclared identifier Signed-off-by: Roman Khimov <[email protected]>
api/response.go:116:14 errorlint type assertion on error will fail on wrapped errors. Use errors.As to check for specific errors api/response.go:234:14 errorlint type assertion on error will fail on wrapped errors. Use errors.As to check for specific errors api/s3errors/errors.go:1689:11 errorlint type assertion on error will fail on wrapped errors. Use errors.As to check for specific errors api/handler/delete.go:145:9 errorlint type switch on error will fail on wrapped errors. Use errors.As to check for specific errors api/handler/delete.go:230:20 errorlint type assertion on error will fail on wrapped errors. Use errors.As to check for specific errors internal/neofs/neofs.go:593:16 errorlint type switch on error will fail on wrapped errors. Use errors.As to check for specific errors Signed-off-by: Roman Khimov <[email protected]>
internal/neofs/tree.go:103:49 errorlint non-wrapping format verb for fmt.Errorf. Use `%w` to format errors Signed-off-by: Roman Khimov <[email protected]>
api/auth/signer/v4/chunked_reader.go:140:8 errorlint comparing with == will fail on wrapped errors. Use errors.Is to check for a specific error api/auth/signer/v4/chunked_reader.go:179:13 errorlint comparing with == will fail on wrapped errors. Use errors.Is to check for a specific error api/auth/signer/v4/chunked_reader.go:195:6 errorlint comparing with == will fail on wrapped errors. Use errors.Is to check for a specific error cmd/s3-gw/service.go:23:20 errorlint comparing with != will fail on wrapped errors. Use errors.Is to check for a specific error Signed-off-by: Roman Khimov <[email protected]>
api/handler/locking_test.go:650:32 bodyclose response body must be closed ... Signed-off-by: Roman Khimov <[email protected]>
Interface-based function is just misleading here: api/router.go:185:42 contextcheck Function `GetRequestID` should pass the context parameter api/layer/container.go:41:25 contextcheck Function `GetRequestID` should pass the context parameter api/layer/container.go:100:25 contextcheck Function `GetRequestID` should pass the context parameter api/handler/locking_test.go:335:64 contextcheck Function `NewReqInfo->GetRequestID` should pass the context parameter Signed-off-by: Roman Khimov <[email protected]>
api/auth/center.go:208:31 contextcheck Function `cloneRequest` should pass the context parameter Signed-off-by: Roman Khimov <[email protected]>
cmd/s3-gw/app.go:478:16 contextcheck Function `stopServices` should pass the context parameter cmd/s3-gw/app.go:507:16 contextcheck Function `stopServices` should pass the context parameter Signed-off-by: Roman Khimov <[email protected]>
internal/neofs/neofs_test.go:225:33 contextcheck Non-inherited new context, use function like `context.WithXXX` instead internal/neofs/neofs_test.go:232:28 contextcheck Non-inherited new context, use function like `context.WithXXX` instead Signed-off-by: Roman Khimov <[email protected]>
api/router.go:137:20 contextcheck Non-inherited new context, use function like `context.WithXXX` or `r.Context` instead Signed-off-by: Roman Khimov <[email protected]>
api/handler/locking_test.go:335:21 contextcheck Non-inherited new context, use function like `context.WithXXX` instead Signed-off-by: Roman Khimov <[email protected]>
roman-khimov
force-pushed
the
org-linter
branch
from
September 16, 2024 15:54
1152204
to
367954b
Compare
Suggest merging the fixes (they're good anyway), but not switching the the linter setup for now. |
smallhive
approved these changes
Sep 17, 2024
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.
No description provided.