kuberay icon indicating copy to clipboard operation
kuberay copied to clipboard

[Chore] Upgrade Golang version to v1.25

Open JiangJiaWei1103 opened this issue 2 weeks ago • 4 comments

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 tidy to 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 :(

JiangJiaWei1103 avatar Dec 14 '25 02:12 JiangJiaWei1103

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!!

JiangJiaWei1103 avatar Dec 14 '25 05:12 JiangJiaWei1103

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)

dentiny avatar Dec 14 '25 09:12 dentiny

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

win5923 avatar Dec 14 '25 11:12 win5923

Thanks @dentiny and @win5923 for the review. Let's wait for https://github.com/ray-project/kuberay/pull/4007 merged first.

JiangJiaWei1103 avatar Dec 14 '25 11:12 JiangJiaWei1103

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!

JiangJiaWei1103 avatar Dec 20 '25 02:12 JiangJiaWei1103

Hi @JiangJiaWei1103, I think the conflicts may need to be resolved again. Thanks!

win5923 avatar Dec 22 '25 08:12 win5923

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.

JiangJiaWei1103 avatar Dec 22 '25 13:12 JiangJiaWei1103