You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
➜ server go mod tidy
go: finding module for package atmax.io/go-workspace/commons/pkg
atmax.io/go-workspace/server imports
atmax.io/go-workspace/commons/pkg: cannot find module providing package atmax.io/go-workspace/commons/pkg: unrecognized import path "atmax.io/go-workspace/commons/pkg": reading https://atmax.io/go-workspace/commons/pkg?go-get=1: 404 Not Found
What did you expect to see?
The go mod tidy should not try to find modules which have been declared in go.work.
What did you see instead?
The go mod tidy try to find modules which have been declared in go.work, and these modules cannot be found in internet, which causes failed.
But the go run command works well.
The text was updated successfully, but these errors were encountered:
Furthermore, some other go mod commands also failed.
go mod vendor
➜ server go mod vendor
atmax.io/go-workspace/server imports
atmax.io/go-workspace/commons/pkg: no required module provides package atmax.io/go-workspace/commons/pkg; to add it:
go get atmax.io/go-workspace/commons/pkg
go mod verify
➜ server go mod verify
atmax.io/go-workspace/server : missing ziphash: open hash: no such file or directory
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?
Reproduction steps:
git clone https://github.com/maxsxu/go-workspace
cd server && go mod tidy
The project structure:
The
commons/go.mod
file:The
server/go.mod
file:The
go mod tidy
failed with below errors:What did you expect to see?
The
go mod tidy
should not try to find modules which have been declared ingo.work
.What did you see instead?
The
go mod tidy
try to find modules which have been declared ingo.work
, and these modules cannot be found in internet, which causes failed.But the
go run
command works well.The text was updated successfully, but these errors were encountered: