-
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/compile: confusing message when go.mod file and vendor folder both present #44149
Comments
What exactly did you do, I can't reproduce the issue as described Also note that names without a dot in the first element are considered reserved for the standard library, using a proper name gives a better error message » mkdir /tmp/example && cd /tmp/example
» go mod init example.com/foo
go: creating new go.mod: module example.com/foo
» cat << EOF > main.go
package main
import _ "aaa"
func main() {}
EOF
» go build
main.go:3:8: package aaa is not in GOROOT (/home/arccy/sdk/gotip/src/aaa)
» mkdir vendor
» go build
main.go:3:8: cannot find package "." in:
/tmp/example/vendor/aaa |
You exactly reproduced the error described above. |
I don't think it's a problem? Without |
OK, but shouldn't the message be
|
that's #38748 |
Looks so. Close it for that. |
What version of Go are you using (
go version
)?What did you do?
What did you expect to see?
package aaa is not in GOROOT (GOROOT/src/aaa)
What did you see instead?
The text was updated successfully, but these errors were encountered: