Turn these kit checks back on in .golangci.overlay.yml and make make lint-check pass. They are disabled under linters.disable on the lint-policy branch (PR #1146). A fresh custom-gcl run with them forced on reports 75 findings, almost all in internal/server/api_test.go.
Done when those names are gone from linters.disable, nolintlint.allow-unused can go back off if no stale //nolint remains, and make lint-check is clean.
unconvert (48)
All in internal/server/api_test.go. They are nested conversions such as Number: int64(int64(prNumber)) on generated-client calls (example: line 2566). Delete the inner conversion. Do not rewrite this with a text replace of int64(int64(; that leaves a spare ) and does not compile.
thelper (11)
Helpers that take *testing.T and do not start with t.Helper():
internal/server/api_test.go (6), including setupTestServerWithRepos
internal/server/e2etest/labels_provider_test.go:221 and :555
internal/server/host_check_test.go:26
internal/server/kata/test_helpers_test.go:101 and :111
usestdlibvars (6)
All in internal/server/api_test.go. String status codes "200", "404", "405", "409", "500" that should be http.StatusOK and the matching constants. Lines 1640, 1670, 11127, 11724, 14804, 14827.
perfsprint (5)
internal/gitclone/commit_stats.go:70: fmt.Errorf with no formatting, use errors.New
internal/server/api_test.go:1699, :3677, :11766: same
internal/server/api_test.go:17584: fmt.Sprintf of an integer, use strconv.Itoa
mirror (2)
internal/server/api_test.go:28285 and :28420. (*strings.Builder).Write instead of the allocating mirror call.
gocritic (3)
internal/server/api_test.go:28747: exitAfterDefer, os.Exit skips defer cancel()
internal/workspace/localruntime/manager_test.go:2961 and :2980: appendAssign, append result is not assigned back to the same slice
Kit already disables the filepath-join gocritic check. Do not turn that back on.
Turn these kit checks back on in
.golangci.overlay.ymland makemake lint-checkpass. They are disabled underlinters.disableon the lint-policy branch (PR #1146). A freshcustom-gclrun with them forced on reports 75 findings, almost all ininternal/server/api_test.go.Done when those names are gone from
linters.disable,nolintlint.allow-unusedcan go back off if no stale//nolintremains, andmake lint-checkis clean.unconvert (48)
All in
internal/server/api_test.go. They are nested conversions such asNumber: int64(int64(prNumber))on generated-client calls (example: line 2566). Delete the inner conversion. Do not rewrite this with a text replace ofint64(int64(; that leaves a spare)and does not compile.thelper (11)
Helpers that take
*testing.Tand do not start witht.Helper():internal/server/api_test.go(6), includingsetupTestServerWithReposinternal/server/e2etest/labels_provider_test.go:221and:555internal/server/host_check_test.go:26internal/server/kata/test_helpers_test.go:101and:111usestdlibvars (6)
All in
internal/server/api_test.go. String status codes"200","404","405","409","500"that should behttp.StatusOKand the matching constants. Lines 1640, 1670, 11127, 11724, 14804, 14827.perfsprint (5)
internal/gitclone/commit_stats.go:70:fmt.Errorfwith no formatting, useerrors.Newinternal/server/api_test.go:1699,:3677,:11766: sameinternal/server/api_test.go:17584:fmt.Sprintfof an integer, usestrconv.Itoamirror (2)
internal/server/api_test.go:28285and:28420.(*strings.Builder).Writeinstead of the allocating mirror call.gocritic (3)
internal/server/api_test.go:28747:exitAfterDefer,os.Exitskipsdefer cancel()internal/workspace/localruntime/manager_test.go:2961and:2980:appendAssign, append result is not assigned back to the same sliceKit already disables the filepath-join
gocriticcheck. Do not turn that back on.