fix: revert golangci-lint pin to latest (Go 1.26 compat) - #69
Merged
Merged
Conversation
Pinning to v2.1.6 caused a panic in CI because it was built with Go 1.24 and cannot analyze Go 1.26 code. Since the workflow uses `go-version: stable` (which floats), pinning golangci-lint will keep breaking on Go updates. Using `latest` with `only-new-issues: true` is the pragmatic fix: - `latest` ensures compatibility with whatever Go stable resolves to - `only-new-issues` mitigates the main risk of `latest` (new lint rules only surface on changed code, not the entire codebase) Co-Authored-By: Claude Opus 4.6 (1M context) <[email protected]>
dunganle
approved these changes
Apr 16, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Problem
PR #68 pinned golangci-lint to
v2.1.6, but that version was built with Go 1.24. Since this workflow usesgo-version: 'stable'(currently Go 1.26.2), golangci-lint panics on every run:This is breaking lint on all repos — e.g., Kochava/mcp#229.
Root cause
Pinning golangci-lint is incompatible with a floating Go version (
stable). When Go bumps, the pinned linter falls behind and crashes. We'd have to update the pin every time Go releases a new version.Fix
Revert
versionback tolatestwhile keepingonly-new-issues: truefrom #68. This is a reasonable tradeoff because:latestensures the linter is always compatible with whatevergo-version: stableresolves toonly-new-issues: truemitigates the main risk oflatest— new lint rules only surface on changed code in PRs, not the entire codebase (per golangci-lint-action docs)fetch-depth: 0from fix: pin golangci-lint version and enable only-new-issues for PRs #68 is already in place for the diff to workAfter merge
The
go/app/v1tag needs to be moved to the new main HEAD for this to take effect.🤖 Generated with Claude Code