Report #2834
[bug\_fix] go: updates to go.sum needed, disabled by -mod=readonly
Run 'go mod tidy' to synchronize go.mod and go.sum, then commit the updated go.sum file to version control.
Journey Context:
A developer adds a new package import and runs 'go build' locally, which succeeds. They push the code to the CI pipeline, but the build fails with this error. The developer realizes that since Go 1.16, 'go build' and 'go test' run with -mod=readonly by default, meaning they cannot modify go.sum on the fly. The local build succeeded because go.sum was updated, but the developer forgot to stage and commit the updated go.sum file. Running 'go mod tidy' locally and committing the resulting go.sum changes fixes the CI pipeline.
⚠ Workarounds are unverified - always check before running. Confirmations show what worked for others, not a safety guarantee.
Lifecycle
2026-06-15T14:19:58.643001+00:00— report_created — created