cmd/go: go.work.sum changes unexpectedly #63901
Labels
GoCommand
cmd/go
modules
NeedsInvestigation
Someone must examine and confirm this is a valid issue and not a duplicate of an existing one.
WaitingForInfo
Issue is not actionable because of missing required information, which needs to be provided.
Milestone
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
)?go env
OutputWhat did you do?
I ran the following testscript script:
What did you expect to see?
A passing test, or at least either
go mod tidy
orgo work sync
should have updated thego.work.sum
file.What did you see instead?
The
go.work.sum
file was updated as a result of runninggo list
, not either of the two previous commands (go mod tidy
andgo work sync
).If I go into the
cmd/ocisrv
directory and rungo mod tidy
, itsgo.sum
file does change (but note: this was not because any code or dependencies have changed in that directory), but there's no easy way to rungo mod tidy
on all modules in a repository, so it's easy to run into annoying CI failures this way.I think that after running
go work sync
, allgo.mod
,go.sum
andgo.work.sum
files should be consistent and not change when running other normal go commands likego list
.The text was updated successfully, but these errors were encountered: