-
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: preserve sums for contents of modules required by go.mod #41103
Comments
Looks like it fixed:
|
@ekalin This is specifically about modules without packages in their root directories, like |
Change https://golang.org/cl/251880 mentions this issue: |
Change https://golang.org/cl/282692 mentions this issue: |
Previously, commands that wrote go.sum (except 'go mod tidy') would retain sums for zip files of directly required modules. Sums of indirect dependencies wouldn't be retained unless they were used to load packages. With this change, sums for indirect dependencies will be retained if they're available. This allows users to add missing sums with 'go mod download example.com/mod', which previously only worked for directly required modules. Note that 'go mod download' without arguments now adds sums for every module in the build list. That matches 1.15 behavior. For #41103 Change-Id: I4cce2bf1c73578dae836bdb5adb32da071554f1a Reviewed-on: https://go-review.googlesource.com/c/go/+/282692 Trust: Jay Conrod <[email protected]> Run-TryBot: Jay Conrod <[email protected]> TryBot-Result: Go Bot <[email protected]> Reviewed-by: Bryan C. Mills <[email protected]>
What version of Go are you using (
go version
)?3b6c812f3defa90bfd7dbddf24bc6135adc5a7eb
Does this issue reproduce with the latest release?
No, this is a regression in 1.16 development, probably caused by CL 237017.
What did you do?
go get
any module that has no package in its root directory.go get
will add a sum for the module'sgo.mod
file togo.sum
, but it won't add a sum for the module's content togo.sum
.What did you expect to see?
go get
should add sums for the module'sgo.mod
file and its content togo.sum
.What did you see instead?
go get
only adds a sum for the module'sgo.mod
file.The text was updated successfully, but these errors were encountered: