[Chore] Upgrade Golang version to v1.25
Why are these changes needed?
Go v1.25 has been released since Aug while KubeRay still uses v1.24.
Changes
- Upgrade Go to v1.25 for Go module files, Dockerfiles, CI/CD configurations, pre-commit, and docs
- Run
go mod tidyto add missing modules and remove unused ones - Bump crd-ref-docs to v0.2.0 (please refer to the review comments below)
- Bump golangci-cli to v2.7.2
Note that Go v1.25 images use newer Debian base variants like Bookworm, so we choose golang:1.25.0-bookworm as the builder.
Related issue number
Closes https://github.com/ray-project/kuberay/issues/4263.
Checks
- [ ] I've made sure the tests are passing.
- Testing Strategy
- [ ] Unit tests
- [ ] Manual tests
- [ ] This PR is not tested :(
Hi @Future-Outlier,
For now, KubeRay depends on [email protected], which is incompatible with Go v1.25. The change log of golangci-lint shows that v2.4.0 is the earliest version to support Go v1.25. As v2.7.2 is shown to be the latest stable version in golangcli-lint CI configuration. Would it make sense to just bump this tool to v2.7.2?
cc @rueian, @dentiny
Thanks!!
Would it make sense to just bump this tool to v2.7.2?
make sense to me, I personally prefer to keep all dependencies and toolchain to the most latest stable version (maybe apart from rust toolchain)
For now, KubeRay depends on [email protected], which is incompatible with Go v1.25. The change log of golangci-lint shows that v2.4.0 is the earliest version to support Go v1.25. As v2.7.2 is shown to be the latest stable version in golangcli-lint CI configuration. Would it make sense to just bump this tool to v2.7.2?
There is already a PR addressing this: https://github.com/ray-project/kuberay/pull/4007, we can wait for this PR to be merged before proceeding with the Go version upgrade. cc @seanlaii
Thanks @dentiny and @win5923 for the review. Let's wait for https://github.com/ray-project/kuberay/pull/4007 merged first.
Hi @JiangJiaWei1103, could you help resolve the conflicts? The golang-lint-ci upgrade have already been merged.
Hi @win5923, I've rebase with the master branch, thanks!
Hi @JiangJiaWei1103, I think the conflicts may need to be resolved again. Thanks!
Hi @win5923,
The conflicts are resolved! Regarding go.work and go.work.sum, @Future-Outlier has opened another PR https://github.com/ray-project/kuberay/pull/4301 to remove them. Thanks!
(Update)
go.work issue is now resolved.