I'm using Golang (1.9 at this time), and using GitLab CI to test and build binaries and Docker containers.
For some projects, I run into this issue (GitLab CI output):
$ go get
$ go get -u github.com/golang/lint/golint
$ go tool vet -composites=false -shadow=true *.go
$ golint ./...
$ go test --race $(go list ./... | grep -v /vendor/)
# gitlab.my.site/core/proj/mypkg mypkg/mypkg_test.go:18:2: cannot find package
"gitlab.my.site/core/otherproj/otherpkg" in any of:
/usr/local/go/src/gitlab.my.site/core/otherproj/otherpkg (from $GOROOT)
/go/src/gitlab.my.site/core/otherproj/otherpkg (from $GOPATH)
FAIL gitlab.my.site/core/proj/mypkg [setup failed]
The core/otherproj
project is private, but clonable through SSH, which is my current workaround.
My main problem is that private projects in dependencies most often work, but sometimes, go get
ting them consistently fails.
Worth noting is that the otherproj/otherpkg
is only a dependency in the test for proj/mypkg
; not its primary functionality.
My question is; why does this specific dependency not download from go get
, and how do I make it download?
Thanks.