golangci-lint v2.12.2 warns on every run: gomodguard is deprecated in favour of gomodguard_v2
#35
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?
Now that hosts actually run the pinned v2.12.2 linter (#24 / #34),
every
make lintandmake check— locally and inside the Docker lintstage — prints:
It is a warning, not a finding:
make lintstill reports0 issues.and exits 0. But it is noise on every gate run, and
gomodguardwilleventually be removed, at which point the config breaks rather than
warns.
The fix is not local:
.golangci.ymlis the standardized shared configand per
REPO_POLICIES.mdmust never be edited in-repo, only replacedwholesale from
https://git.eeqj.de/sneak/prompts/raw/branch/main/.golangci.yml. Sothis needs
gomodguardswapped forgomodguard_v2in the canonicalfile upstream, and then a pull of the updated copy into this repo (the
same shape as #3).
Definition of done
.golangci.ymlenablesgomodguard_v2instead ofgomodguard..golangci.ymlis replaced with the updated canonicalcopy — not hand-edited.
make lintruns without deprecation warnings and still reports0 issues.;make checkandmake dockergreen.Duplicate of #26 — closing in favour of it.
#26 was filed earlier from the same finding during the review of PR #2, and is already assigned to
sneakwith the two options written out and a recommendation, because the fix belongs in the canonical.golangci.ymlin thepromptsrepo and agents are forbidden to modify that file.The observation here is correct and independently reached, which is worth something: v2.12.2 warns on every run that
gomodguardis deprecated in favour ofgomodguard_v2, and now that #24 makes hosts actually run the pinned linter, that warning will be visible on every developer machine rather than only inside the Docker lint stage. Recorded on #26.Nothing to do here. Follow #26.