-
Notifications
You must be signed in to change notification settings - Fork 1.7k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
FATA[0000] Failed to build operator binary: failed to exec []string #6198
Comments
@KailashPatilKP do you have to use Operator SDK version If you absolutely need to use Operator SDK version I hope this helps! |
Additionally, I would also highly recommend to either scaffold the project in the GOPATH or activate module support. This error usually happens in Go when it assumes that the package is outside a module (https://cs.opensource.google/go/go/+/refs/tags/go1.19.3:src/cmd/go/internal/modindex/read.go;l=157). However, maintaining the supported SDK+Go version compatibility will be helpful to avoid any unexpected errors. |
Issues go stale after 90d of inactivity. Mark the issue as fresh by commenting If this issue is safe to close now please do so with /lifecycle stale |
Stale issues rot after 30d of inactivity. Mark the issue as fresh by commenting If this issue is safe to close now please do so with /lifecycle rotten |
Rotten issues close after 30d of inactivity. Reopen the issue by commenting /close |
@openshift-bot: Closing this issue. In response to this:
Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository. |
Bug Report
What did you do?
I'm trying to execute the command (docker push <DOCKER_REGISTRY_URL>/<USER_NAME>/siddhi-operator:) but it's failing with below error.
`panic: modindex.GetPackage called with empty modroot
goroutine 19 [running]:
cmd/go/internal/modindex.GetModule({0x0, 0x0})
/usr/local/Cellar/go/1.19.3/libexec/src/cmd/go/internal/modindex/read.go:157 +0x125
cmd/go/internal/modindex.GetPackage({0x0, 0x0}, {0xc0000ee680, 0x7e})
/usr/local/Cellar/go/1.19.3/libexec/src/cmd/go/internal/modindex/read.go:135 +0x31
cmd/go/internal/modload.scanDir({0x0?, 0x7e?}, {0xc0000ee680, 0x7e}, 0x0?)
/usr/local/Cellar/go/1.19.3/libexec/src/cmd/go/internal/modload/load.go:2105 +0x4b
cmd/go/internal/modload.(*loader).load(0xc000155380, {0x172f930, 0xc0000b2000}, 0xc000155520)
/usr/local/Cellar/go/1.19.3/libexec/src/cmd/go/internal/modload/load.go:1734 +0x35f
cmd/go/internal/modload.(*loader).pkg.func1.1()
/usr/local/Cellar/go/1.19.3/libexec/src/cmd/go/internal/modload/load.go:1517 +0x29
cmd/go/internal/par.(*Queue).Add.func1()
/usr/local/Cellar/go/1.19.3/libexec/src/cmd/go/internal/par/queue.go:58 +0x7d
created by cmd/go/internal/par.(*Queue).Add
/usr/local/Cellar/go/1.19.3/libexec/src/cmd/go/internal/par/queue.go:56 +0x225
FATA[0000] Failed to build operator binary: failed to exec []string{"go", "build", "-o", "/Users/kailash.patil/Downloads/operator-sdk-v0.19.0/operator-sdk/vendor/github.com/siddhi-io/siddhi-operator/build/_output/bin/siddhi-operator", "-gcflags", "all=-trimpath=/Users/kailash.patil/Downloads/operator-sdk-v0.19.0/operator-sdk/vendor/github.com/siddhi-io", "-asmflags", "all=-trimpath=/Users/kailash.patil/Downloads/operator-sdk-v0.19.0/operator-sdk/vendor/github.com/siddhi-io", "-mod=vendor", "Users/kailash.patil/Downloads/operator-sdk-v0.19.0/operator-sdk/vendor/github.com/siddhi-io/siddhi-operator/cmd/manager"}: exit status 2 `
What did you expect to see?
Command executed successfully and image is created.
What did you see instead? Under which circumstances?
Encountered issue while executing the command.
Environment
Operator type:
/language go
Kubernetes cluster type:
docker-desktop
$ operator-sdk version
operator-sdk version: "v0.19.0", commit: "8e28aca60994c5cb1aec0251b85f0116cc4c9427", kubernetes version: "v1.18.2", go version: "go1.13.10 darwin/amd64"
$ go version
(if language is Go)go version go1.19.3 darwin/amd64
$ kubectl version
Client Version: version.Info{Major:"1", Minor:"18", GitVersion:"v1.18.6", GitCommit:"dff82dc0de47299ab66c83c626e08b245ab19037", GitTreeState:"clean", BuildDate:"2020-07-15T16:58:53Z", GoVersion:"go1.13.9", Compiler:"gc", Platform:"darwin/amd64"}
Possible Solution
Additional context
The text was updated successfully, but these errors were encountered: