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

x/tools/gopls: respect the default checks of the staticcheck tool #44712

Closed
hyangah opened this issue Mar 1, 2021 · 1 comment
Closed

x/tools/gopls: respect the default checks of the staticcheck tool #44712

hyangah opened this issue Mar 1, 2021 · 1 comment
Labels
Documentation FrozenDueToAge gopls Issues related to the Go language server, gopls. Tools This label describes issues relating to any tools in the x/tools repository.
Milestone

Comments

@hyangah
Copy link
Contributor

hyangah commented Mar 1, 2021

While testing for golang/vscode-go#1257, I noticed that the staticcheck offered from gopls includes ST1021 that's a non-default check in the standalone staticcheck tool. (I am using v0.6.6 gopls)

Since vscode-go is currently telling users to use staticcheck offered by gopls instead of using the lintOnSave feature when using staticcheck as the lint tool, I think it's desirable to respect the default offered by the standalone tool. Otherwise, we need to document the difference and why.

@gopherbot gopherbot added Tools This label describes issues relating to any tools in the x/tools repository. gopls Issues related to the Go language server, gopls. labels Mar 1, 2021
@gopherbot gopherbot added this to the Unreleased milestone Mar 1, 2021
@stamblerre stamblerre modified the milestones: Unreleased, gopls/v1.0.0 Mar 1, 2021
@stamblerre stamblerre changed the title x/tools/gopls: respect the default checks of the staticcheck tool or document the difference x/tools/gopls: respect the default checks of the staticcheck tooll Mar 1, 2021
@stamblerre stamblerre changed the title x/tools/gopls: respect the default checks of the staticcheck tooll x/tools/gopls: respect the default checks of the staticcheck tool Mar 1, 2021
@stamblerre stamblerre added this to To Do in gopls on-deck Mar 11, 2021
ShoshinNikita added a commit to ShoshinNikita/tools that referenced this issue Apr 15, 2021
Disable non-default checks by default. Also, update the regression
test because the previous version used a non-default check (ST1022).

Fixes golang/go#44712
@gopherbot
Copy link

Change https://golang.org/cl/310449 mentions this issue: gopls/internal/hooks: respect the default checks of the staticcheck tool

gopls on-deck automation moved this from To Do to Done Apr 15, 2021
@golang golang locked and limited conversation to collaborators Apr 15, 2022
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Documentation FrozenDueToAge gopls Issues related to the Go language server, gopls. Tools This label describes issues relating to any tools in the x/tools repository.
Projects
No open projects
Development

Successfully merging a pull request may close this issue.

3 participants