apache / apache/uniffle

[Bug] I cannot build Uniffle operator with Go with version later than 1.19

Open
#2,722 1 comment 0 reactions 0 assignees View on GitHub
Dominant language
Java
Stars
454
Forks
172
Avg merge
5d 17h
Merged PRs (30d)
5

Description

### Code of Conduct

- [x] I agree to follow this project's [Code of Conduct](https://www.apache.org/foundation/policies/conduct)

### Search before asking

- [x] I have searched in the [issues](https://github.com/apache/incubator-uniffle/issues?q=is%3Aissue) and found no similar issues.

### Describe the bug

I have cloned the repository and I wanted to deploy Uniffle on Kubernetes.
I tried to build the operator, but in my Ubuntu box I have go 1.25 (latest).

The workaround is to downgrade Go to 1.19.
One problem is that 1.19 is so old that brew and other tools don't allow to install it easily (I had to go in the Archives and down load the old version)

```
./build-operator.sh
Build and Test kubernetes operator...
./hack/update-codegen.sh
Generating deepcopy funcs
Generating clientset for uniffle:v1alpha1 at github.com/apache/incubator-uniffle/deploy/kubernetes/operator/pkg/generated/clientset
Generating listers for uniffle:v1alpha1 at github.com/apache/incubator-uniffle/deploy/kubernetes/operator/pkg/generated/listers
Generating informers for uniffle:v1alpha1 at github.com/apache/incubator-uniffle/deploy/kubernetes/operator/pkg/generated/informers
/home/eolivelli/dev/uniffle/uniffle/deploy/kubernetes/operator/local/controller-gen rbac:roleName=manager-role crd webhook paths="./..." output:crd:artifacts:config=config/crd/bases
panic: runtime error: invalid memory address or nil pointer dereference [recovered]
panic: runtime error: invalid memory address or nil pointer dereference
[signal SIGSEGV: segmentation violation code=0x1 addr=0x0 pc=0xa0b7af]

goroutine 188 [running]:
go/types.(*Checker).handleBailout(0xc0001a3800, 0xc001bcfd40)
/usr/lib/go-1.22/src/go/types/check.go:367 +0x88
panic({0xbc51a0?, 0x12b0ca0?})
/usr/lib/go-1.22/src/runtime/panic.go:770 +0x132
go/types.(*StdSizes).Sizeof(0x0, {0xdc0078, 0x12b94c0})
```

### Affects Version(s)

0.10.0

### Uniffle Server Log Output

```logtalk

```

### Uniffle Engine Log Output

```logtalk

```

### Uniffle Server Configurations

```yaml

```

### Uniffle Engine Configurations

```yaml

```

### Additional context

_No response_

### Are you willing to submit PR?

- [ ] Yes I am willing to submit a PR!

Contributor guide

Open the contributing guide

Research direction

Start by running build-operator.sh with a current Go version and trace the failure through hack/update-codegen.sh and the local controller-gen invocation under deploy/kubernetes/operator. Compare the operator's declared Go and code-generation tool versions with the reported Go 1.22–1.25 behavior. Done means operator code generation and the full build-and-test flow complete without requiring Go 1.19.

Written by the indexing model from the issue text.

Assessment

Tech stack
go, kubernetes
Domain
build-system, devops
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
42/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.