DECISION: golangci-lint warns gomodguard is deprecated, but .golangci.yml must stay canonical #29
Reference in New Issue
Block a user
Delete Branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Problem
Every
make lintrun now emits:It does not affect the result —
mainis still 0 issues — but it is noise onevery run, and deprecations are action items rather than background hum.
Nobody can fix it in this repo.
.golangci.ymlhere is byte-identical tothe org canonical config (sha256
021cc83f4e6fc7c31b95b34b846723dfcf20b66b7baeea1dc40406e643346bcb), andMEMORY.mdforbids editing it without your explicit permission. Changing itlocally would break the very property that makes it verifiable.
Three separate agents have now flagged this and all three correctly declined
to act. Filing it so it stops recurring as an advisory on every PR.
Why it is your call
The fix belongs upstream in the canonical config, not here. Two things
need deciding:
gomodguard→gomodguard_v2in the shared config atall, and when.
changes, or lags.
Both affect every repo that vendors this config, so neither is a per-repo
decision.
Options
A. Migrate upstream, then re-sync here. Swap the linter in the canonical
.golangci.yml, re-hash, and update every repo that vendors it (here it is aone-line
linters.enablechange plus a new expected sha256). Correct anddurable. Costs a coordinated sweep across repos.
B. Do nothing for now. The warning is harmless and
gomodguardstillworks. Revisit when golangci-lint actually removes it — at which point it
becomes a hard failure rather than a warning, on every repo simultaneously,
possibly at an inconvenient moment.
C. Suppress locally. Rejected, and listed only to be explicit: it would
require editing
.golangci.yml, breaking byte-identity with canonical. Do notdo this.
Recommendation
Option A, but not urgently. The migration is a one-line change per repo;
the risk is that a future golangci-lint release removes
gomodguardoutrightand turns a warning into a red gate everywhere at once, with no warning window
left to plan in. Doing it deliberately now is cheaper than doing it under
pressure later.
Note this is entangled with #4: if you adopt a hash-pinned linter there, the
deprecation stops being a moving target, because the version that produces the
warning becomes a fixed, known quantity rather than whatever the host happens
to have. Worth deciding #4 first.
Definition of done
Not actionable in this repo until you rule. Once the canonical config changes:
make lintruns with no deprecation warning, still reports 0 issues, and.golangci.ymlstill matches the canonical file's new hash exactly.Assigning to you. Not blocking — everything else continues.
create a PR to fix in upstream, obviously.