-
Notifications
You must be signed in to change notification settings - Fork 17.9k
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 mod verify replaces tags manually set in go.mod #27271
Comments
In case this helps, a couple quick initial comments regarding "the The VCS tag For a VCS tag to be interpreted as a semver tag by the go tooling, the tag must encode a semantic version in the form A non-semver tag used in a In general, module queries that do not resolve to a semver tag will be recorded as pseudo-versions in the The "Module-aware go get" and "Module queries" sections of the tip documentation have a bit more info on these topics... @gopherbot please add label modules |
We use the -mod=vendor strategy for building, and we add a target on Makefile called vendor. Apparently go-mod expects semver (vX.Y.Z) naming for tags/branches, but kubernetes-1.13.2 is not in that format so for k8s.io/xxx packages it gets replaced to v0.0.0-commit id every time we run go mod, see: golang/go#27271 Go automatically detects ginkgo/gomega usage, and adds it to the go.mod file, resulting in vendoring those pkgs, which may be ok if we want to provide a built version of the e2e binary as kubefed will be doing soon.
We use the -mod=vendor strategy for building, and we add a target on Makefile called vendor. Apparently go-mod expects semver (vX.Y.Z) naming for tags/branches, but kubernetes-1.13.2 is not in that format so for k8s.io/xxx packages it gets replaced to v0.0.0-commit id every time we run go mod, see: golang/go#27271 Go automatically detects ginkgo/gomega usage, and adds it to the go.mod file, resulting in vendoring those pkgs, which may be ok if we want to provide a built version of the e2e binary as kubefed will be doing soon.
This commit moves compilation into go mod, removing the vendored sources. Go will automatically download and install modules although you'll need to setup GO111MODULE=on in your env Apparently go-mod expects semver (vX.Y.Z) naming for tags/branches, but kubernetes-1.13.2 is not in that format so for k8s.io/xxx packages it gets replaced to v0.0.0-commit id every time we run go mod, see: golang/go#27271 Go automatically detects ginkgo/gomega usage, and adds it to the go.mod file, resulting in vendoring those pkgs, which may be ok if we want to provide a built version of the e2e binary as kubefed will be doing soon.
This commit moves compilation into go mod, removing the vendored sources. Go will automatically download and install modules although you'll need to setup GO111MODULE=on in your env Apparently go-mod expects semver (vX.Y.Z) naming for tags/branches, but kubernetes-1.13.2 is not in that format so for k8s.io/xxx packages it gets replaced to v0.0.0-commit id every time we run go mod, see: golang/go#27271 Go automatically detects ginkgo/gomega usage, and adds it to the go.mod file, resulting in vendoring those pkgs, which may be ok if we want to provide a built version of the e2e binary as kubefed will be doing soon.
This commit moves compilation into go mod, removing the vendored sources. Go will automatically download and install modules although you'll need to setup GO111MODULE=on in your env Apparently go-mod expects semver (vX.Y.Z) naming for tags/branches, but kubernetes-1.13.2 is not in that format so for k8s.io/xxx packages it gets replaced to v0.0.0-commit id every time we run go mod, see: golang/go#27271 Go automatically detects ginkgo/gomega usage, and adds it to the go.mod file, resulting in vendoring those pkgs, which may be ok if we want to provide a built version of the e2e binary as kubefed will be doing soon.
This commit moves compilation into go mod, removing the vendored sources. Go will automatically download and install modules although you'll need to setup GO111MODULE=on in your env Apparently go-mod expects semver (vX.Y.Z) naming for tags/branches, but kubernetes-1.13.2 is not in that format so for k8s.io/xxx packages it gets replaced to v0.0.0-commit id every time we run go mod, see: golang/go#27271 Go automatically detects ginkgo/gomega usage, and adds it to the go.mod file, resulting in vendoring those pkgs, which may be ok if we want to provide a built version of the e2e binary as kubefed will be doing soon.
This commit moves compilation into go mod, removing the vendored sources. Go will automatically download and install modules although you'll need to setup GO111MODULE=on in your env Apparently go-mod expects semver (vX.Y.Z) naming for tags/branches, but kubernetes-1.13.2 is not in that format so for k8s.io/xxx packages it gets replaced to v0.0.0-commit id every time we run go mod, see: golang/go#27271 Go automatically detects ginkgo/gomega usage, and adds it to the go.mod file, resulting in vendoring those pkgs, which may be ok if we want to provide a built version of the e2e binary as kubefed will be doing soon.
This commit moves compilation into go mod, removing the vendored sources. Go will automatically download and install modules although you'll need to setup GO111MODULE=on in your env Apparently go-mod expects semver (vX.Y.Z) naming for tags/branches, but kubernetes-1.13.2 is not in that format so for k8s.io/xxx packages it gets replaced to v0.0.0-commit id every time we run go mod, see: golang/go#27271 Go automatically detects ginkgo/gomega usage, and adds it to the go.mod file, resulting in vendoring those pkgs, which may be ok if we want to provide a built version of the e2e binary as kubefed will be doing soon.
This commit moves compilation into go mod, removing the vendored sources. Go will automatically download and install modules although you'll need to setup GO111MODULE=on in your env Apparently go-mod expects semver (vX.Y.Z) naming for tags/branches, but kubernetes-1.13.2 is not in that format so for k8s.io/xxx packages it gets replaced to v0.0.0-commit id every time we run go mod, see: golang/go#27271 Go automatically detects ginkgo/gomega usage, and adds it to the go.mod file, resulting in vendoring those pkgs, which may be ok if we want to provide a built version of the e2e binary as kubefed will be doing soon.
Please answer these questions before submitting your issue. Thanks!
What version of Go are you using (
go version
)?Does this issue reproduce with the latest release?
Yes
What operating system and processor architecture are you using (
go env
)?What did you do?
Create a
main.go
file with:Have the
go.mod
file written with the contentrun
GO111MODULE=on go mod tidy
Verify the content of
go.mod
and noticek8s.io/client kubernetes-1.11.2
was not kept nor a reference to the tag manually set.What did you expect to see?
k8s.io/client-go
to keep tagkubernetes-1.11.2
(nice to have but not important)
2. All the indirect dependencies are extremely verbose. If I care about them I would check
go.sum
, I don't see the point on filling up therequire
, which IMO should be kept by the developer, to be filled up with transient dependencies.The text was updated successfully, but these errors were encountered: