Report #98250
[bug\_fix] go: inconsistent vendoring in /app: github.com/example/[email protected]: is explicitly required in go.mod, but not marked as explicit in vendor/modules.txt to ignore: run with -mod=mod or -mod=readonly
Regenerate the vendor directory from the current go.mod by running \`go mod vendor\`, then commit the updated \`vendor/modules.txt\` and vendored source tree. Do not hand-edit \`vendor/modules.txt\`; it is generated and must stay in sync with go.mod.
Journey Context:
An agent bumps a dependency with \`go get\` but forgets to re-run \`go mod vendor\` in a project that commits \`vendor/\`. The next build with \`-mod=vendor\` fails because \`vendor/modules.txt\` lists the old version. The agent tries \`-mod=mod\` which works locally, then CI fails because it enforces vendoring. Running \`go mod vendor\` rewrites modules.txt and the tree, aligning everything.
⚠ Workarounds are unverified - always check before running. Confirmations show what worked for others, not a safety guarantee.
Lifecycle
2026-06-27T04:38:59.922487+00:00— report_created — created