could not import myproject/game/helper2 (cannot find package “myproject/game/helper2” in any of
/usr/local/go/src/myproject/game/helper2 (from $GOROOT)
/home/prasnjit/dev/go/src/myproject/game/helper2 (from $GOPATH))compiler
Hi! You should change your import statement with import "myproject/game" and call the public function Get with game.Get(). my project/game sees all public types and declarations and you always can use/call them with the package name as prefix , in this case game..
Ahhh you’re creating a go module with main name! , you mustn’t create any kind of identifier , package or module with a name already used in Go global scope. Create again your module with go mod init myproject or simply change go.mod first line