-
-
Notifications
You must be signed in to change notification settings - Fork 1.4k
internal compiler error: have package "main" want package "..." #3583
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
Comments
Hey, thank you for opening your first Issue ! 🙂 If you would like to contribute we have a guide for contributors. |
Hello, It is the same expected behavior as $ go build -tags=tools .
tools.go:6:8: import "github.com/onsi/ginkgo/v2/ginkgo" is a program, not an importable package So I think it is something related to Go. |
Thank you for your response @ldez. I have modified the issue description a bit. Originally, it included also
but that error can be removed by adding The error that I'm reporting is
|
Note: The directive So I think that something has changed in the go tool chain. |
Ah, sorry my mistake! Thank you for clarification. However, any use of |
It doesn't seem related to this issue. |
Ok, my guess was purely based on similar error mentioned there
|
The problem seems fixed now: $ docker run --rm -v $(pwd):/app -w /app golangci/golangci-lint:v1.57.0 golangci-lint run --build-tags=tools
$ |
Welcome
Description of the problem
After upgrading to go1.20 typecheck results in compiler error for
tools.go
file. The file is following a common pattern described here.The error looks like following
See the code example below to reproduce the error.
Possibly related to golang/go#54542
Version of golangci-lint
Configuration file
Go environment
Verbose output of running
Code example or link to a public repository
The text was updated successfully, but these errors were encountered: