gofumpt: rule in v0.3.0 deleted, formatting now conflicts with golangci linting #2638
-
Welcome
Description of the problemIn mvdan/gofumpt@6333469, a gofumpt rule was deleted. This change is published within the newest release v0.3.0 of gofumpt. The latest release of golangci-lint still uses gofumpt in version v0.2.1, which leads to a conflict. If I format my code with recent version of gofumpt, gloangci-lint will throw an error when running the gofumpt linter. The used version of gofumpt was already bumped in 5ffadac, it would be really nice to see a release with this change soon. Version of golangci-lint$ golangci-lint --version
golangci-lint has version 1.44.2 built from d58dbde5 on 2022-02-17T20:58:06Z Configuration file$ cat .golangci.yml
cat: .golangci.yml: No such file or directory Go environment$ go version && go env
go version go1.17.1 linux/amd64 Verbose output of running$ gofumpt -l .
$ golangci-lint run ./... --disable-all --enable gofumpt
xxx.go gofumpt File is not `gofumpt`-ed Code example or link to a public repositorytype foo interface {
a() error
b() error
} |
Beta Was this translation helpful? Give feedback.
Replies: 2 comments 1 reply
-
Hey, thank you for opening your first Issue ! 🙂 If you would like to contribute we have a guide for contributors. |
Beta Was this translation helpful? Give feedback.
-
As you already noticed yourself this is not a bug and the version is bumped and will be a part of the next release. This will happen for all linters if they're run separate from |
Beta Was this translation helpful? Give feedback.
As you already noticed yourself this is not a bug and the version is bumped and will be a part of the next release. This will happen for all linters if they're run separate from
golangci-lint
and the version mismatch. If you're not able to wait for a new release ofgolangci-lint
, building a new version from main might be an alternative.