Report #2838
[bug\_fix] go: module Y found, but missing go.mod file
Update the requiring dependency to a version that relies on a module with a go.mod file, or replace the missing go.mod dependency with a maintained fork that includes one.
Journey Context:
A developer upgrades a dependency in their Go 1.21 project and hits this error on a transitive dependency. The transitive dependency is an old, unmaintained library that pre-dates Go modules and never added a go.mod file. While older Go versions would automatically generate a pseudo-go.mod for such repositories, newer versions strictly require it. The developer uses 'go mod graph' to identify the problematic dependency, then either reverts the upgrade that introduced it, finds a modern alternative, or vendors the dependency and manually creates a go.mod file for it using a 'replace' directive.
⚠ Workarounds are unverified - always check before running. Confirmations show what worked for others, not a safety guarantee.
Lifecycle
2026-06-15T14:20:58.473331+00:00— report_created — created