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

x/vgo: vgo build fails on successive builds #23984

Closed
robertlestak opened this issue Feb 21, 2018 · 2 comments
Closed

x/vgo: vgo build fails on successive builds #23984

robertlestak opened this issue Feb 21, 2018 · 2 comments
Milestone

Comments

@robertlestak
Copy link

Please answer these questions before submitting your issue. Thanks!

What version of Go are you using (go version)?

go1.10 darwin/amd64

Does this issue reproduce with the latest release?

yes

What operating system and processor architecture are you using (go env)?

darwin/amd64

What did you do?

First vgo build command will build project properly. Successive vgo build commands will fail with a 404 error on certain packages.

What did you expect to see?

Successful build.

What did you see instead?

vgo: finding github.com/rs/cors v1.2.0
vgo: github.com/rs/cors v1.2.0: unexpected status (https://api.github.com/repos/rs/cors/git/refs/tags/v1.2.0): 404 Not Found
vgo: finding github.com/google/uuid v0.1.0
vgo: github.com/google/uuid v0.1.0: unexpected status (https://api.github.com/repos/google/uuid/git/refs/tags/v0.1.0): 404 Not Found
vgo: finding github.com/google/uuid v0.1.0
vgo: github.com/google/uuid v0.1.0: unexpected status (https://api.github.com/repos/google/uuid/git/refs/tags/v0.1.0): 404 Not Found
vgo: unexpected status (https://api.github.com/repos/google/uuid/git/refs/tags/v0.1.0): 404 Not Found
@gopherbot gopherbot added this to the vgo milestone Feb 21, 2018
@flibustenet
Copy link

I believe it's the same issue #23954 when the tagged version is not three numbers

@robertlestak
Copy link
Author

robertlestak commented Feb 22, 2018

After some further testing - if a package has no tags, it will pull from the HEAD and the pseudo-version is used as defined in vgo-intro - Defining Go Modules. However if the package is tagged - but not with 3 numbers - it causes the 404 error when running vgo build or vgo run.

To remedy this, one can manually set the package's pseudo-version in the go.mod file using the commit hash:

require (
        "github.com/google/uuid" v0.0.0-20171129175443-dec09d7
	"github.com/rs/cors" v0.0.0-20180122175443-feef513
)

@golang golang locked and limited conversation to collaborators Feb 22, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

3 participants