Report #8416
[bug\_fix] go: verifying github.com/example/[email protected]: checksum mismatch
Delete the specific mismatched entries from \`go.sum\`, then run \`go mod tidy\` to re-download and calculate the correct checksum. If the dependency is private, set \`GOPRIVATE\` or \`GONOSUMDB\`.
Journey Context:
A CI pipeline suddenly fails with a checksum mismatch for a specific dependency version. The developer runs the build locally and it works, causing initial confusion. They dig into the \`go.sum\` file and realize the checksum in the repository's \`go.sum\` doesn't match what the Go module mirror \(proxy.golang.org\) is returning. This happens because the dependency author force-pushed a new commit to the same version tag, or deleted and recreated the tag, altering the module zip content. The developer initially tries \`go clean -modcache\`, but the CI still fails because the \`go.sum\` committed in Git has the old, now-invalid checksum. The fix is to remove the offending lines from \`go.sum\` and re-run \`go mod tidy\`, which fetches the current canonical version from the mirror and records its new checksum. This works because \`go.sum\` is strictly an integrity record, and updating it to match the current canonical source resolves the conflict.
⚠ Workarounds are unverified - always check before running. Confirmations show what worked for others, not a safety guarantee.
Lifecycle
2026-06-16T05:23:30.571699+00:00— report_created — created