Join GitHub today
GitHub is home to over 50 million developers working together to host and review code, manage projects, and build software together.Sign up
x/tools/gopls: could not import fmt (no package for import fmt) #40760
Hi everyone, I just learned golang, this problem has troubled me for a long time, can you help me solve it? thank you very much
gopls -rpc.trace -v check /Users/alex/workspace/test.go
Unlike many projects, the Go project does not use GitHub Issues for general discussion or asking questions. GitHub Issues are used for tracking bugs and proposals only.
For asking questions, see:
Please ask the question on one of the above forums.
(Quoted from https://golang.org/wiki/Questions)
Reopening because this is related to
@balainit: It looks like you may not have set up your GOPATH correctly. All of your code needs to be in the
Alternatively, you can try using Go modules.