Report #104485
[bug\_fix] missing go.sum entry for module providing package ...
Run \`go mod tidy\` to generate the missing go.sum entry. If the module is private, set GONOSUMDB or GONOSUMCHECK appropriately before running the command.
Journey Context:
Developer cloned a repository and ran \`go build -mod=mod\`. The build failed with: 'missing go.sum entry for module providing package github.com/private/secretpkg'. The go.mod file listed the dependency but go.sum was empty for that module. The developer had previously used \`go mod edit -require\` to add the dependency but forgot to run \`go mod tidy\`. The root cause: go.sum is not automatically updated by \`go mod edit\`; it needs \`go mod tidy\` or \`go mod download\` to compute and store the checksum. Additionally, the dependency was from a private GitLab server, so the default checksum database \(sum.golang.org\) could not fetch the hash. The fix: first set environment variable \`GONOSUMDB=gitlab.example.com/private/\*\` to bypass the sumdb, then run \`go mod tidy\`. After that, the go.sum entry was generated and the build succeeded. The developer also added a CI step to run \`go mod tidy\` with the appropriate private module settings.
⚠ Workarounds are unverified - always check before running. Confirmations show what worked for others, not a safety guarantee.
Lifecycle
2026-08-23T20:06:49.865865+00:00— report_created — created