Skip to content

Conversation

Electronic-Waste
Copy link
Member

What this PR does / why we need it:

We should support the latest k8s v1.32 release https://github.com/kubernetes/kubernetes/releases/tag/v1.32.2.

Kubeflow Trainer has decided to support Kubernetes v1.32 kubeflow/trainer#2434. We'd better upgrade the Kubernetes version to maintain consistency with Trainer.

/cc @kubeflow/wg-automl-leads @helenxie-bit @mahdikhashan @Doris-xm @truc0

Which issue(s) this PR fixes (optional, in fixes #<issue number>(, fixes #<issue_number>, ...) format, will close the issue(s) when PR gets merged):
Fixes #2516

Checklist:

  • Docs included if any changes are user facing

@google-oss-prow google-oss-prow bot requested review from a team, Doris-xm, helenxie-bit and mahdikhashan March 2, 2025 05:59
Copy link

@Electronic-Waste: GitHub didn't allow me to request PR reviews from the following users: truc0.

Note that only kubeflow members and repo collaborators can review this PR, and authors cannot review their own PRs.

In response to this:

What this PR does / why we need it:

We should support the latest k8s v1.32 release https://github.com/kubernetes/kubernetes/releases/tag/v1.32.2.

Kubeflow Trainer has decided to support Kubernetes v1.32 kubeflow/trainer#2434. We'd better upgrade the Kubernetes version to maintain consistency with Trainer.

/cc @kubeflow/wg-automl-leads @helenxie-bit @mahdikhashan @Doris-xm @truc0

Which issue(s) this PR fixes (optional, in fixes #<issue number>(, fixes #<issue_number>, ...) format, will close the issue(s) when PR gets merged):
Fixes #2516

Checklist:

  • Docs included if any changes are user facing

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.

Copy link
Member Author

@Electronic-Waste Electronic-Waste left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This PR is ready for the review. PTAL if you have time👀

@kubeflow/wg-automl-leads @helenxie-bit @mahdikhashan @Doris-xm @truc0

Comment on lines +55 to +56
succeededBatchJobName = "test-job-succeeded"
failedBatchJobName = "test-job-failed"
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We need to separate the Trial run with "Failed" BatchJob. test and other tests. That's because:

  • If a Job is succeeded, we need to set Complete and SuccessCriteriaMet Conditions in the Job status
  • If a Job is failed, we need to set Failed and FailureTarget Conditions in the Job status

And we can't mutate these completion conditions, or we will get:

Invalid value: cannot disable the terminal Failed=True condition, status.conditions: Invalid value: cannot disable the terminal FailureTarget=True condition,

So we need to separate these UTs with two different Job Names.

Comment on lines 279 to 284
// TODO(Electronic-Waste): Remove this condition when K8s 1.30 is no longer supported.
// SuccessPolicy is available in K8s 1.31 and later. If we set it in K8s 1.30, it will be ignored.
// And when we set the status with `SuccessCriteriaMet`, it will report error:
// "Invalid value: cannot set SuccessCriteriaMet=True for Job without SuccessPolicy".
// REF: https://kubernetes.io/docs/concepts/workloads/controllers/job/#success-policy
isK8sVersion130 := strings.Contains(os.Getenv("KUBEBUILDER_ASSETS"), "1.30")
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We need to remove this when we do not plan to support Kubernetes v1.30.

Related CI error: https://github.com/kubeflow/katib/actions/runs/13613616097/job/38053846460

@Electronic-Waste Electronic-Waste marked this pull request as ready for review March 2, 2025 12:06
@Electronic-Waste
Copy link
Member Author

/rerun-all

Makefile Outdated
lint:
ifndef HAS_LINT
go install github.com/golangci/golangci-lint/cmd/golangci-lint@v1.57.2
go install github.com/golangci/golangci-lint/cmd/golangci-lint@v1.60.1
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Update this because support for Go 1.23 starts from v1.60.1

https://golangci-lint.run/product/changelog/#v1601

@Electronic-Waste
Copy link
Member Author

/rerun-all

Copy link

github-actions bot commented Jun 5, 2025

This pull request has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.

@Electronic-Waste
Copy link
Member Author

/remove-lifecycle stale

matrix:
# Detail: `setup-envtest list`
kubernetes-version: ["1.29.3", "1.30.0", "1.31.0"]
kubernetes-version: ["1.29.3", "1.30.0", "1.31.0", "1.32.0"]
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

do we need to have 1.32.2 here as well?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Sorry for the late response. If I remember correctly, that's because envtest did not have 1.32.2 version.

@mahdikhashan
Copy link
Member

mahdikhashan commented Jun 5, 2025

SGTM, (i dono why / l g t m didn't work)

Copy link

github-actions bot commented Sep 3, 2025

This pull request has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.

@andreyvelich
Copy link
Member

/remove-lifecycle stale
@Electronic-Waste Could you finalize this PR please ?
Maybe we can directly upgrade to k8s 1.34 like in Trainer: kubeflow/trainer#2804

@Electronic-Waste
Copy link
Member Author

Electronic-Waste commented Sep 5, 2025

@Electronic-Waste Could you finalize this PR please ?

Sure. I'll resolve the conflict.

Maybe we can directly upgrade to k8s 1.34 like in Trainer: kubeflow/trainer#2804

I don't think it's a good practice to directly upgrade k8s version to 1.34. We need to gradually upgrade the version so that we can roll back to the older version if faced with incompatibility:)

WDYT? @andreyvelich

…elease-0.20.

Signed-off-by: Electronic-Waste <2690692950@qq.com>
Signed-off-by: Electronic-Waste <2690692950@qq.com>
Signed-off-by: Electronic-Waste <2690692950@qq.com>
Signed-off-by: Electronic-Waste <2690692950@qq.com>
Signed-off-by: Electronic-Waste <2690692950@qq.com>
Signed-off-by: Electronic-Waste <2690692950@qq.com>
Signed-off-by: Electronic-Waste <2690692950@qq.com>
Signed-off-by: Electronic-Waste <2690692950@qq.com>
Signed-off-by: Electronic-Waste <2690692950@qq.com>
Signed-off-by: Electronic-Waste <2690692950@qq.com>
Signed-off-by: Electronic-Waste <2690692950@qq.com>
Signed-off-by: Electronic-Waste <2690692950@qq.com>
Signed-off-by: Electronic-Waste <2690692950@qq.com>
Signed-off-by: Electronic-Waste <2690692950@qq.com>
Signed-off-by: Electronic-Waste <2690692950@qq.com>
Signed-off-by: Electronic-Waste <2690692950@qq.com>
Signed-off-by: Electronic-Waste <2690692950@qq.com>
Signed-off-by: Electronic-Waste <2690692950@qq.com>
Signed-off-by: Electronic-Waste <2690692950@qq.com>
@andreyvelich
Copy link
Member

I don't think it's a good practice to directly upgrade k8s version to 1.34. We need to gradually upgrade the version so that we can roll back to the older version if faced with incompatibility:)

Sure, we can split it between 2 PRs, but in the next Katib release I want us to support same k8s version as in Trainer.

@Electronic-Waste
Copy link
Member Author

@andreyvelich Sure, I'll create another PR after this

@Electronic-Waste
Copy link
Member Author

/retest

Copy link
Member

@andreyvelich andreyvelich left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@Electronic-Waste Are we ready to merge this ?

@Electronic-Waste
Copy link
Member Author

@andreyvelich I think we're ready to merge this.

Copy link
Member

@andreyvelich andreyvelich left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

/lgtm
/approve
@Electronic-Waste Please create the followup PR to support k8s 1.33

Copy link

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: andreyvelich

The full list of commands accepted by this bot can be found here.

The pull request process is described here

Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@google-oss-prow google-oss-prow bot merged commit 82260cb into kubeflow:master Sep 13, 2025
83 of 84 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Support Kubernetes v1.32

3 participants