Adopt canonical .golangci.yml and golangci-lint v2.12.2 #30
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?
Tracking issue for the lint-toolchain upgrade already implemented on branch
golangci-v2.12.2(PR #29). Filed retroactively so the work is tracked here, which is authoritative.Background
The repo carried a bespoke
.golangci.yml: an enable-only list of roughly 20 linters,lllat 120,tests: false, and a blanket exclusion ofinternal/macse. Org policy (REPO_POLICIES.md) requires the canonical standardized config, which an agent must never modify:>
.golangci.ymlis standardized and must NEVER be modified by an agent, only manually by the user. Fetch fromhttps://git.eeqj.de/sneak/prompts/raw/branch/main/.golangci.yml.Definition of done
.golangci.ymlis byte-identical to the canonical org config, sha256021cc83f4e6fc7c31b95b34b846723dfcf20b66b7baeea1dc40406e643346bcb.Dockerfilelint stage pins golangci-lint v2.12.2 by tag and sha256 digest, with the version-and-date comment above the reference that policy requires.//nolintwithout a written reason on the same line.make checkgreen, and CI green on the PR head.TODO.mdupdated in the same commit as the work.Implementation requirements
funlen/cyclop/duplmust be provably behavior-preserving, especially anywhere amemguard.LockedBufferis created, passed, or destroyed — an extraction that changes when a buffer goes out of scope changes how long key material lives in memory.noctxfixes that convertexec.Commandtoexec.CommandContextmust not introduce a context that can cancel agpgorsecurityinvocation mid-write and leave a partially written vault file.err113sentinel-error refactors must preserveerrors.Is/errors.Asbehavior for every caller, and must not widen or narrow which errors a caller treats as fatal.paralleltestadditions must not addt.Parallel()to any test that shares a state directory, mutates the process environment, or depends on memguard global state.Notes
This is a prerequisite for the rest of the 1.0.0 milestone: it touches 59 files across all of
internal/andpkg/, so every security fix filed under this milestone will conflict with it until it lands. It goes through the gate first.