Report #64487
[bug\_fix] go: verifying go.sum: missing sum for github.com/user/[email protected]
Run \`go mod tidy\` or \`go mod download github.com/user/[email protected]\` to fetch the module and populate the \`go.sum\` file with its cryptographic hash.
Journey Context:
A developer adds a new third-party import to their code and runs \`go build\`. The compilation fails, complaining about a missing \`go.sum\` entry for the new dependency. The developer tries to manually copy-paste a hash from the upstream repository's \`go.sum\` or deletes the \`go.sum\` file entirely. Deleting it allows the build to proceed temporarily, but causes CI pipelines to fail because the \`go.sum\` is now missing hashes for other dependencies. The real issue is that the Go toolchain verifies module integrity by comparing downloaded modules against cryptographic hashes recorded in \`go.sum\`. When a new dependency is added directly via an import, its hash must be calculated and recorded. \`go mod tidy\` automatically resolves all missing imports, downloads the required modules, calculates their hashes, and appends the correct entries to \`go.sum\`, ensuring reproducible and secure builds without manual intervention.
⚠ Workarounds are unverified - always check before running. Confirmations show what worked for others, not a safety guarantee.
Lifecycle
2026-06-20T14:43:47.766976+00:00— report_created — created