The problem
golangci-lint v1 cannot analyze this repo any more. Running the current pinned line against a Go 1.27 toolchain fails to load packages at all:
pkg/log/log.go:9:2: could not import sync/atomic (-: could not load export data:
internal error in importing "sync/atomic" (cannot decode "sync/atomic",
export data version 4 is greater than maximum supported version 2)) (typecheck)
Every subsequent typecheck error is an artifact of that failure, not real. The linter appears to run (in make janitor and the pre-commit hook) while effectively checking nothing — a silent quality gap.
golangci-lint v1 is end-of-life; current upstream is v2.13.1.
Why it is not a one-line bump
v2 changed the configuration schema: .golangci.yml needs a version: "2" key, linters.enable moved, and run.build-tags relocated. Upstream ships a migration command:
Bundle into the same change: 6 dead linters
These are enabled in .golangci.yml but inactive or removed — three of them log "fully inactivated: it will not produce any reports":
| enabled linter |
status |
replacement |
execinquery |
archived upstream, inactivated |
— |
exportloopref |
obsolete since Go 1.22 loopvar |
copyloopvar |
tenv |
duplicate feature |
usetesting |
rowserrcheck, sqlclosecheck, wastedassign |
deprecated in v1 |
(n/a — no SQL in this repo) |
Expect real findings
Because linting has effectively been off, the migration will surface a batch of genuine issues. That is the point, but it means this should be reviewed rather than automerged.
Also in scope
- The pre-commit hook (
dnephin/pre-commit-golang, .pre-commit-config.yaml) invokes the same config and is skipped on pre-commit.ci — re-check it after the migration
make janitor had --go=1.19 hardcoded (removed in the Makefile cleanup PR); confirm v2 picks the language version up from go.mod
🤖 Issue drafted with Claude Code
The problem
golangci-lintv1 cannot analyze this repo any more. Running the current pinned line against a Go 1.27 toolchain fails to load packages at all:Every subsequent
typecheckerror is an artifact of that failure, not real. The linter appears to run (inmake janitorand the pre-commit hook) while effectively checking nothing — a silent quality gap.golangci-lint v1 is end-of-life; current upstream is v2.13.1.
Why it is not a one-line bump
v2 changed the configuration schema:
.golangci.ymlneeds aversion: "2"key,linters.enablemoved, andrun.build-tagsrelocated. Upstream ships a migration command:Bundle into the same change: 6 dead linters
These are enabled in
.golangci.ymlbut inactive or removed — three of them log "fully inactivated: it will not produce any reports":execinqueryexportlooprefcopyloopvartenvusetestingrowserrcheck,sqlclosecheck,wastedassignExpect real findings
Because linting has effectively been off, the migration will surface a batch of genuine issues. That is the point, but it means this should be reviewed rather than automerged.
Also in scope
dnephin/pre-commit-golang,.pre-commit-config.yaml) invokes the same config and is skipped on pre-commit.ci — re-check it after the migrationmake janitorhad--go=1.19hardcoded (removed in the Makefile cleanup PR); confirm v2 picks the language version up from go.mod🤖 Issue drafted with Claude Code