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: a go get invocation produces an "invalid version: unknown revision" loop #55898

Closed
anacrolix opened this issue Sep 28, 2022 · 5 comments
Labels
FrozenDueToAge GoCommand cmd/go NeedsInvestigation Someone must examine and confirm this is a valid issue and not a duplicate of an existing one.
Milestone

Comments

@anacrolix
Copy link
Contributor

This issue occurs in Go 1.18, and 1.19, and several other versions I've tried. To reproduce:

cd `mktemp -d`
go mod init hello
go get github.com/anacrolix/torrent

This gives:

go: github.com/anacrolix/dht/v2@v2.15.2-0.20220123034220-0538803801cb: invalid version: unknown revision 0538803801cb

I know this revision is missing, it likely disappeared in a rebase or something, and may finally have been flushed from the Google proxy. Both the github.com/anacrolix/torrent and github.com/anacrolix/dht/v2 modules depend on each other (but there are no circular package dependencies or it wouldn't compile). I believe they depend on versions that trickle down to the revision that is missing above, but it's not possible to break this cycle. In recent versions I've made both modules depend on versions of each other that shouldn't depend on older versions that trickle down but it doesn't work. You can try my latest attempt to break this cycle via go get github.com/anacrolix/torrent@unknown-dht-version using the reproduce steps above.

The downstream issue is anacrolix/torrent#776.

@anacrolix
Copy link
Contributor Author

Go 1.16 helpfully produces more output:

go get: github.com/anacrolix/torrent@v1.40.1 updating to
	github.com/anacrolix/torrent@v1.47.0 requires
	github.com/anacrolix/dht/v2@v2.19.0 requires
	github.com/anacrolix/torrent@v1.46.0 requires
	github.com/anacrolix/dht/v2@v2.16.2-0.20220311024416-dd658f18fd51 requires
	github.com/anacrolix/torrent@v1.41.1-0.20220309095723-02b6ee995497 requires
	github.com/anacrolix/dht/v2@v2.15.2-0.20220123034220-0538803801cb: invalid version: unknown revision 0538803801cb

@dmitshur dmitshur changed the title invalid version: unknown revision loop cmd/go: a go get invocation produces an "invalid version: unknown revision" loop Sep 28, 2022
@dmitshur dmitshur added NeedsInvestigation Someone must examine and confirm this is a valid issue and not a duplicate of an existing one. GoCommand cmd/go labels Sep 28, 2022
@dmitshur dmitshur added this to the Backlog milestone Sep 28, 2022
@dmitshur
Copy link
Contributor

CC @bcmills, @matloob.

@bcmills
Copy link
Contributor

bcmills commented Sep 28, 2022

Duplicate of #48024

@bcmills bcmills marked this as a duplicate of #48024 Sep 28, 2022
@bcmills
Copy link
Contributor

bcmills commented Sep 28, 2022

Closing as duplicate.

(I'll give some specific guidance on how to resolve the problem on anacrolix/torrent#776 later today — I don't mean to leave you in the lurch!)

@bcmills bcmills closed this as not planned Won't fix, can't repro, duplicate, stale Sep 28, 2022
@anacrolix
Copy link
Contributor Author

This issue has mutated into #55955.

@golang golang locked and limited conversation to collaborators Sep 30, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
FrozenDueToAge GoCommand cmd/go NeedsInvestigation Someone must examine and confirm this is a valid issue and not a duplicate of an existing one.
Projects
None yet
Development

No branches or pull requests

4 participants