From f996065e40b3ec01b5b2c4ddb68cf43494772874 Mon Sep 17 00:00:00 2001 From: Chris McGehee Date: Fri, 21 May 2021 20:56:55 -0700 Subject: [PATCH] Fix lint issues: gomnd linter --- .golangci.yml | 2 +- checks/checkforfile.go | 2 +- stats/views.go | 1 + 3 files changed, 3 insertions(+), 2 deletions(-) diff --git a/.golangci.yml b/.golangci.yml index f097269c..fb7c8748 100644 --- a/.golangci.yml +++ b/.golangci.yml @@ -29,7 +29,7 @@ linters: - goheader - goimports # - golint - # - gomnd + - gomnd - gomodguard - goprintffuncname - gosec diff --git a/checks/checkforfile.go b/checks/checkforfile.go index 8cd20b73..ecf3e500 100644 --- a/checks/checkforfile.go +++ b/checks/checkforfile.go @@ -74,7 +74,7 @@ func CheckIfFileExists(checkName string, c *checker.CheckRequest, onFile func(na return checker.CheckResult{ Name: checkName, Pass: false, - Confidence: 10, + Confidence: checker.MaxResultConfidence, Error: err, } } diff --git a/stats/views.go b/stats/views.go index 8b4cc505..3c38d3db 100644 --- a/stats/views.go +++ b/stats/views.go @@ -26,6 +26,7 @@ var ( Description: "CPU runtime stats per repo per check", Measure: CPURuntimeInSec, TagKeys: []tag.Key{Repo, CheckName}, + //nolint:gomnd Aggregation: view.Distribution( 1<<2, 1<<3,