Home > Back-end >  go verify module failed (how does go sumsdb work?)
go verify module failed (how does go sumsdb work?)

Time:03-25

I encountered this error on go build:

go: github.com/frankban/[email protected]: verifying module: github.com/frankban/[email protected]: Get "https://sum.golang.org/lookup/github.com/frankban/[email protected]": Not Found

My question is, why the frankban/quicktest is not found in sum db? as a matter of fact this is not the only package that caused this error, last time I try to compile the same project (about an hour ago), the error was on golang.org/x/xerrors.

Further more, could anyone explain (or point out some documents/articles/blogs) on how the go module system's "sums db" work. It is very frustrating if anyone encounter such error as there seems nothing you can do to fix it?

Full log:

$ go get -u
go: downloading github.com/tealeg/xlsx v1.0.5
go: downloading github.com/shabbyrobe/xmlwriter v0.0.0-20220218224045-defe0ad214f6
go: downloading github.com/frankban/quicktest v1.14.2
go: downloading golang.org/x/text v0.3.3
go: downloading github.com/google/btree v1.0.1
go: downloading github.com/kr/pretty v0.3.0
go: downloading golang.org/x/xerrors v0.0.0-20191204190536-9bdfabe68543
go: downloading github.com/kr/text v0.2.0
go: github.com/frankban/[email protected]: verifying module: github.com/frankban/[email protected]: Get "https://sum.golang.org/lookup/github.com/frankban/[email protected]": Not Found
go: github.com/google/[email protected]: verifying module: github.com/google/[email protected]: Get "https://sum.golang.org/lookup/github.com/google/[email protected]": Not Found
go: github.com/kr/[email protected]: verifying module: github.com/kr/[email protected]: Get "https://sum.golang.org/lookup/github.com/kr/[email protected]": Not Found
go: github.com/kr/[email protected]: verifying module: github.com/kr/[email protected]: Get "https://sum.golang.org/lookup/github.com/kr/[email protected]": Not Found
go: github.com/shabbyrobe/[email protected]: verifying module: github.com/shabbyrobe/[email protected]: Get "https://sum.golang.org/lookup/github.com/shabbyrobe/[email protected]": Not Found

CodePudding user response:

The sum.golang.org server needs some time to update the hash sum. Try again now. Everything works correctly for me:

$ GO111MODULE=on go get github.com/shabbyrobe/[email protected]
go: downloading github.com/shabbyrobe/xmlwriter v0.0.0-20220218224045-defe0ad214f6
go: downloading golang.org/x/text v0.3.2
$ curl https://sum.golang.org/lookup/github.com/shabbyrobe/[email protected]
9249991
github.com/shabbyrobe/xmlwriter v0.0.0-20220218224045-defe0ad214f6 h1:ri617veNyNwEMXywzcLmU//YIVSFdJvdk39lNsFB/Ro=
github.com/shabbyrobe/xmlwriter v0.0.0-20220218224045-defe0ad214f6/go.mod h1:tKYSeHyJGYz7eoZMlzrRDQSfdYPYt0UduMr8b97Mmaw=

go.sum database tree
9690070
OufFSNsOUYeDJ2VPyrxBAe7/d47lQYkE03JZL2ltaI8=

— sum.golang.org Az3grkvrWUkW3Rvnl5QL72oZpiY5ifJhab3/evZCb0hmRkEtGRE/tCMyFDXftZWFi2SF71EuHAxJMTgLd1laHabOzAE=
  • Related