When I tried to run go get in a golang project root path ChaatzFeaturePhoneServer. It prompts
go get
package FeaturePhoneServer/routers: unrecognized import path "FeaturePhoneServer/routers"
I am rather confused about it. What is the possible cause of it? How can I find out the cause and fix it?
Check your GOPATH
environment variable:
go
expect to find FeaturePhoneServer/routers
in $GOPATH/src
(see go build
)
Avoid relative import paths.
If the error persists, you can also check your GOROOT
and go installation, as in this question.