xxxxxxxxxx
export GOROOT=/usr/lib/go
export GOPATH=$HOME/go
export PATH=$PATH:$GOROOT/bin:$GOPATH/bin
Make sure you have set "go.gopath" in vocode settings json correctly. You can get the path by running this command
echo $GOPATH
If you didn't set you global go path then you can run this command to add it
xxxxxxxxxx
export GOPATH=$(go env GOPATH)