Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

cmd/go: 'go get […]/v2@v2.X.Y' fails when the repo root contains the go.mod file for […]/v2 but no .go source files [1.13 backport] #34747

gopherbot opened this issue Oct 7, 2019 · 2 comments


Copy link

@gopherbot gopherbot commented Oct 7, 2019

@bcmills requested issue #34746 to be considered for backport to the next 1.13 minor release.

@gopherbot, please backport to 1.13. This was a regression, and the fix goes with #34497 (already backported).


This comment has been minimized.

Copy link

@gopherbot gopherbot commented Oct 9, 2019

Change mentions this issue: [release-branch.go1.13] cmd/go: suppress more errors in package-to-module loading


This comment has been minimized.

Copy link

@gopherbot gopherbot commented Oct 9, 2019

Closed by merging 842a1e7 to release-branch.go1.13.

@gopherbot gopherbot closed this Oct 9, 2019
gopherbot pushed a commit that referenced this issue Oct 9, 2019
…dule loading

In CL 197059, I suppressed errors if the target package was already found.
However, that does not cover the case of passing a '/v2' module path to
'go get' when the module does not contain a package at its root.

This CL is a minimal fix for that case, intended to be backportable to 1.13.

(Longer term, I intend to rework the version-validation check to treat
all mismatched paths as ErrNotExist.)

Updates #34746
Fixes #34747

Change-Id: Ia963c2ea00fae424812b8f46a4d6c2c668252147
Run-TryBot: Bryan C. Mills <>
TryBot-Result: Gobot Gobot <>
Reviewed-by: Jay Conrod <>
(cherry picked from commit 421d35c)
@katiehockman katiehockman modified the milestones: Go1.13.2, Go1.13.3 Oct 17, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
None yet
5 participants
You can’t perform that action at this time.