diff --git a/.golangci.yml b/.golangci.yml index d820c3703e22..9b2d786f7a05 100644 --- a/.golangci.yml +++ b/.golangci.yml @@ -152,6 +152,10 @@ issues: - gomnd - lll + - path: pkg/golinters + linters: + - dupl + - path: pkg/golinters/errcheck.go linters: [staticcheck] text: "SA1019: errCfg.Exclude is deprecated: use ExcludeFunctions instead" @@ -166,9 +170,9 @@ issues: - path: pkg/commands/config.go text: "SA1019: cfg.Run.UseDefaultSkipDirs is deprecated: use Issues.UseDefaultExcludeDirs instead." - - path: pkg/golinters - linters: - - dupl + - path: pkg/golinters/godot.go + linters: [staticcheck] + text: "SA1019: settings.CheckAll is deprecated: use `Scope` instead" - path: pkg/golinters/gofumpt.go linters: [staticcheck] diff --git a/pkg/golinters/godot.go b/pkg/golinters/godot.go index b0ee64434936..06c160fec613 100644 --- a/pkg/golinters/godot.go +++ b/pkg/golinters/godot.go @@ -30,7 +30,7 @@ func NewGodot(settings *config.GodotSettings) *goanalysis.Linter { // Convert deprecated setting // todo(butuzov): remove on v2 release - if settings.CheckAll { //nolint:staticcheck // Keep for retro-compatibility. + if settings.CheckAll { dotSettings.Scope = godot.AllScope } } diff --git a/pkg/golinters/govet.go b/pkg/golinters/govet.go index 504ed8a7525b..ecd406e3bf21 100644 --- a/pkg/golinters/govet.go +++ b/pkg/golinters/govet.go @@ -184,6 +184,12 @@ func isAnalyzerEnabled(name string, cfg *config.GovetSettings, defaultAnalyzers return false } + // TODO(ldez) re-enable httpresponse once https://github.com/golangci/golangci-lint/issues/4482 is fixed. + if name == httpresponse.Analyzer.Name { + govetDebugf("httpresponse is disabled due to panic. See https://github.com/golang/go/issues/66259") + return false + } + // Keeping for backward compatibility. if cfg.CheckShadowing && name == shadow.Analyzer.Name { return true