-
-
Notifications
You must be signed in to change notification settings - Fork 1.4k
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
megacheck, unused, gosimple had been deprecated in favor of staticcheck #357
Comments
@lopezator thank you, I know and I've already updated megacheck code recently to the latest version. But I decided to not replace gosimple, staticcheck, unused and megacheck by staticcheck because this renaming wasn't backward compatible. Some users enabled only staticcheck in config and don't want gosimple to be enabled in a new release. Maybe you have ideas how to rename it without breaking configuration of existing users? |
The easy path is to follow semver rules (see point 2) MAJOR version when you make incompatible API changes. And go for a new major version v2.0.0. That doesn't mean we have to stop new features (or patch fixes) in v1, but it will freeze at one point. There two different strategies to follow here:
Both have it's pros and cons. Posible middle solutions I can think of are hard to write and maintain:
https://docs.docker.com/compose/compose-file/compose-versioning/
|
This comment was marked as off-topic.
This comment was marked as off-topic.
Hello @jirfag any news on this? What would be the plan on this? just updating staticcheck to latest version? In that case I think we should add a note that the recommended usage from now is staticcheck and that megacheck, gosimple, unused are deprecated although you keep them also for compatibility reasons. Related: https://twitter.com/dominikhonnef/status/1155646606940803072 Would yo accept a PR updating the statickcheck to latest 2019.2.2? https://github.com/dominikh/go-tools/releases Thanks. |
An idea to do not break backwards compatibility and do not deprecate older tools might be adding a property to staticcheck config, called, for example:
This flag (false by default) would enable the possibility to use the new staticcheck (gosimple, megacheck, unused are now called simply staticcheck from this version). |
Now that you are back @jirfag, I am still interested on moving this forward, and could take this. Just need some feedback on the proposed design. |
Is this issue already solved? It seems like staticcheck is already available. Just double-checking... |
staticcheck is up-to-date in golangci-lint, and we update the dependency automatically via dependabot. The issue is still opened because the merge of the 4 linters is breaking, so it will be done in the next major version (v2). |
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions. |
Hi, is this still going to be taken care of? What is the ETA of v2? |
I noticed this by running [staticcheck](https://staticcheck.dev). Unfortunately, golangci-lint is still using a deprecated version of this linter. See [here](golangci/golangci-lint#853) and [here](golangci/golangci-lint#357). Signed-off-by: Mihai Todor <[email protected]>
I noticed this by running [staticcheck](https://staticcheck.dev). Unfortunately, golangci-lint is still using a deprecated version of this linter. See [here](golangci/golangci-lint#853) and [here](golangci/golangci-lint#357). Signed-off-by: Mihai Todor <[email protected]> Signed-off-by: harshit-sp <[email protected]>
Megacheck, unused and gosimple had been deprecated in favor of staticcheck.
https://github.com/dominikh/go-tools/tree/master/cmd/gosimple
https://github.com/dominikh/go-tools/tree/master/cmd/megacheck
https://github.com/dominikh/go-tools/tree/master/cmd/unused
So I think it makes sense that we remove them in golangci-lint and go through staticcheck implementation to update it and check if we need to add or fix something.
CC/ @jirfag
The text was updated successfully, but these errors were encountered: