go
module_error
ai_generated
true
verifying module: checksum mismatch
ID: go/module-checksum-mismatch
85%Fix Rate
88%Confidence
50Evidence
2023-01-01First Seen
Version Compatibility
| Version | Status | Introduced | Deprecated | Notes |
|---|---|---|---|---|
| 1 | active | — | — | — |
Root Cause
The downloaded module content does not match the checksum recorded in go.sum. This can indicate a corrupted cache, a tampered module, or a module author who re-tagged a release.
genericWorkarounds
-
88% success Clean the module cache and re-download
go clean -modcache && go mod download
-
85% success Delete go.sum and regenerate it
rm go.sum && go mod tidy
Sources: https://go.dev/ref/mod#go-mod-tidy
Dead Ends
Common approaches that don't work:
-
Set GONOSUMCHECK to skip verification entirely
85% fail
Disables supply chain security — allows tampered or malicious modules to be used without detection
-
Manually edit go.sum to replace the hash
75% fail
The checksum database (sum.golang.org) will still reject the mismatch; manual edits create further inconsistencies
Error Chain
Leads to:
Preceded by:
Frequently confused with: