-
Notifications
You must be signed in to change notification settings - Fork 17.7k
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
on a pseudo-version of a package not at the repo root fails with preceding tag (…) not found
when fetching from git
#47650
Comments
(because it isn't clear to me whether this is actually a bug in |
Interestingly, |
FWIW I'm running into something very similar to this with golang.org/x/tools:
This is with |
@bcmills This is in the 1.18 milestone; time to move to 1.19? Thanks. |
It should still be fixed — it's a fairly serious issue in version resolution. Unfortunately it needs some involved work to fix correctly, and I've had limited capability for focused work this cycle due to burnout. |
Not sure if this is the same but it seems it could be like #58116:
Got this error too while building packages for DragonFlyBSD. Example:
Is there any workaround? |
This may be related to #56881. |
Thankfully, the original reproducer for this still succeeds in reproducing it, so I hope to make progress on it soon.
|
In this case the relevant tag is |
The subdirectory in the
|
Change https://go.dev/cl/548475 mentions this issue: |
I also ran into this issue when forking a project and changing imports to my new github url. I fixed it by doing 3 fake tags and on the 3rd try everything pulled correctly. |
go get
on a pseudo-version of a package not at the repo root fails with preceding tag (…) not found
when fetching from git
Change https://go.dev/cl/549155 mentions this issue: |
…/git/issue57650.txt Updates #47650. Change-Id: I90c0a51b390326129643d5b90fe935d44e5e5372 Reviewed-on: https://go-review.googlesource.com/c/go/+/549155 TryBot-Result: Gopher Robot <gobot@golang.org> Run-TryBot: Bryan Mills <bcmills@google.com> Auto-Submit: Bryan Mills <bcmills@google.com> Reviewed-by: Michael Matloob <matloob@golang.org>
…Query If we encounter an unclassified error in modload.Query, it takes precedence even if the package is found in some other module. (That is intentional, so that if a package exists in both a parent and a nested module the outcome is deterministic, and does not shift if a temporary error causes one of the modules to be unavailable.) A pseudo-version is formed from a base version and a commit hash. Each version tag is specific to the module in a particular directory of the repo (often the root directory), whereas the commit hash is the same for all subdirectories. When we go to check a particular subdirectory for the requested package, we may find that that version is not valid for that combination of <subdirectory, commit hash>, but we should keep looking to see whether it is valid for a module in some other subdirectory. Fixes golang#47650. Change-Id: Id48f590ce906a3d4cf4e82fc66137bf67613277d Cq-Include-Trybots: luci.golang.try:gotip-linux-amd64-longtest,gotip-windows-amd64-longtest Reviewed-on: https://go-review.googlesource.com/c/go/+/548475 Reviewed-by: Michael Matloob <matloob@golang.org> LUCI-TryBot-Result: Go LUCI <golang-scoped@luci-project-accounts.iam.gserviceaccount.com> Auto-Submit: Bryan Mills <bcmills@google.com>
…/git/issue57650.txt Updates golang#47650. Change-Id: I90c0a51b390326129643d5b90fe935d44e5e5372 Reviewed-on: https://go-review.googlesource.com/c/go/+/549155 TryBot-Result: Gopher Robot <gobot@golang.org> Run-TryBot: Bryan Mills <bcmills@google.com> Auto-Submit: Bryan Mills <bcmills@google.com> Reviewed-by: Michael Matloob <matloob@golang.org>
From a report from @hyangah:
The text was updated successfully, but these errors were encountered: