.golangci.yml: simplify#2566
Conversation
mtrmac
left a comment
There was a problem hiding this comment.
Thanks!
I’m generally very skeptical of detailed linter configuration given our limited capacity (containers/image#2244 ), because that’s committing us to a long-term maintenance effort.
I’d prefer not to deviate from defaults if at all possible.
| checks: | ||
| - all | ||
| - -ST1000 # Incorrect or missing package comment. | ||
| - -ST1005 # Incorrectly formatted error string. |
There was a problem hiding this comment.
This is not the same thing as the previous one. I don’t really want to be in the business of micromanaging this.
(Before version: "2", the configuration used to start with inherit, with us adding only the exceptions, but that no longer works for some reason.)
There was a problem hiding this comment.
This is not the same thing as the previous one.
Right, it's not. As per commit message, this patch removes some unused exclusions.
My thinking is, it makes no sense to disable warnings which we never hit. If and when we hit those warnings, we can decide on a case by case basis whether we prefer to exclude or fix those.
As to "let's stick to golangci-lint defaults" mantra, I generally agree, but in this case we clearly already don't follow it. Since we deviate, it's probably best to minimize the linter configuration.
There was a problem hiding this comment.
If and when we hit those warnings, we can decide on a case by case basis whether we prefer to exclude or fix those.
= committing to spend more time on this in the future…
… Fine. Would documenting all # Compared to Golangci-lint 2.0.2 defaults, we don’t exclude "-ST1003", "-ST1016", "-ST1020", "-ST1021", "-ST1022" because we don’t currently hit those work?
|
Second commit removed. |
|
Ephemeral COPR build failed. @containers/packit-build please check. |
Remove some unused exclusions, document the used ones. Signed-off-by: Kir Kolyshkin <kolyshkin@gmail.com>
|
The Packit rawhide failures should go away once the copr buildroot gets a new libgpg-error. |
Add(dropped)errorlint, fix found warnings ("Use%wto format errors").