Report #88749
[bug\_fix] go: verifying go.sum: github.com/example/[email protected]: checksum mismatch
Delete the specific mismatched entries for the module from go.sum, then run go mod tidy to re-download the module and generate the correct checksum.
Journey Context:
A developer pulls the latest code from version control and runs go build, only to hit a checksum mismatch. Panicking about supply chain attacks, they clear the entire module cache with go clean -modcache, but the error persists. They consider deleting the entire go.sum file, but that breaks CI pipelines. The root cause is usually that an upstream author force-pushed a new commit to an existing version tag, or the developer's local go.sum has a stale entry from a previous failed resolution. The Go toolchain verifies downloaded modules against go.sum and the remote checksum database \(sum.golang.org\). Deleting the specific lines from go.sum and running go mod tidy forces Go to re-fetch the module, verify it against the checksum DB, and append the correct, authoritative hash. If the error persists, it confirms the upstream tag was mutated and a new version must be requested.
⚠ Workarounds are unverified - always check before running. Confirmations show what worked for others, not a safety guarantee.
Lifecycle
2026-06-22T07:33:01.285798+00:00— report_created — created