-
Notifications
You must be signed in to change notification settings - Fork 1.4k
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
Error: unable to load the configuration: unable to read "PROJECT" file: read PROJECT: is a directory get error #2666
Comments
Hi @631068264, Are using a go version >= 1.17 and < 1.18 ? I am unable to reproduce this one. Could you please let us know more about ? |
go version go1.17.6 darwin/amd64 OSX 12.3.1 I just download it , remove it to the cmd It's confused that I just want to get version or set zsh why it‘s related to a "porject"? |
Are you able to create new projects?
The PROJECT file is where we store the data about the PROJECT scaffold. |
Hi @631068264, I am unable to reproduce this issue:
I was a bug in the past, so you might call an old binary instead of this version ( it probably is another place in your local env ) when you see this error. See #2126 ( this fix was released with v3.0.0: https://github.com/kubernetes-sigs/kubebuilder/releases/tag/v3.0.0
GOPATH is the path of your Golang local environment. Check your golang env. ($ go env) I'd recommend you remove this bin from /usr/local/bin/kubebuilder and run the kubebuilder version it probably will still be called, and you probably have a kubebuilder CLI binary installed in another place. Then, remove the kubebuilder bin from all places ( you can check that by running kuebuilder version until it does not output command not found you have a bin installed in your local env ). After that try to re-install the latest version or this specific release. |
I can confirm the issue. This is a recurring one, even with v3.0.0 |
Hi @geetikabatra, Could you please do the test with the full path to the bin? a) to show the version:
b) to reproduce the issue c) to check if the profile is the config for another bin. Now only run |
full path test
even I download the latest version get same error
go env
just only one version
|
Hi @631068264, I tried to reproduce your scenario with the latest releases, and I am unable. Another thing that calls my attention is that you are using GOVERSION="go1.18.1" ad it is not supported Could you check if that might no be the root cause as well? |
I am closing this one since it seems like caused by not being using the golang version not supported ( see https://book.kubebuilder.io/quick-start.html#prerequisites ) or an old bin where the fix was not done. However, please feel free to re-open this one if you see that it is required. |
I can replicate this issue, and I just got the reason. because I have a $ ls
go.mod main.go
$ mkdir project
$ cat main.go
package main
import (
"fmt"
"os"
)
func main() {
stat, err := os.Stat("PROJECT")
if err != nil {
panic(err)
}
fmt.Println(stat.Name(), stat.IsDir())
}
$ go run main.go
PROJECT true I'm not sure why the os.Stat function is not case-sensitive, maybe it's a bug? |
I think filesystem is not case-sensitive.
|
What broke? What's expected?
downlowd from https://github.com/kubernetes-sigs/kubebuilder/releases/download/v3.4.0/kubebuilder_darwin_amd64
follow it https://book.kubebuilder.io/quick-start.html#installation to install
use
kubebuilder version
get same errorReproducing this issue
No response
KubeBuilder (CLI) Version
3.4.0
PROJECT version
No response
Plugin versions
No response
Other versions
No response
Extra Labels
No response
The text was updated successfully, but these errors were encountered: