golangci-lint: remove "strict" checking

The corresponding "pull-kubernetes-verify-lint" job was already removed
earlier. Manual strict checking was still possible, but doesn't really make
sense for the same reasons why the job was removed (e.g. the decisions which
checks should be "strict" were too arbitrary).

The explanations for "hints" no longer end with "In general please prefer to
fix the error, ..." because that was misleading and only really applied to the
checks for existing code. For those checks we prefer to fix errors instead of
suppressing them, but not for hints.
This commit is contained in:
Patrick Ohly
2025-01-29 09:39:53 +01:00
parent 6e3546228d
commit 949385731f
6 changed files with 7 additions and 299 deletions

View File

@@ -2,8 +2,6 @@
# enable an increasing amount of checks:
# - golangci.yaml is the most permissive configuration. All existing code
# passed.
# - golangci-strict.yaml adds checks that all new code in pull requests
# must pass.
# - golangci-hints.yaml adds checks for code patterns where developer
# and reviewer may decide whether findings should get addressed before
# merging. Beware that the golangci-lint output includes also the
@@ -171,11 +169,6 @@ linters:
{{- if not .Base }}
- usestdlibvars
{{- end}}
{{- if .Strict}}
disable:
# https://github.com/kubernetes/kubernetes/issues/117288#issuecomment-1507008359
- errcheck
{{- end}}
linters-settings: # please keep this alphabetized
custom: