Skip to content
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

Fix for Sample YAML Config Test - 2.4.0 Failure due to 'suspend' Field #1096

Merged

Conversation

Yicheng-Lu-llll
Copy link
Contributor

@Yicheng-Lu-llll Yicheng-Lu-llll commented May 18, 2023

Why are these changes needed?

#926 adds the suspend: false field to ray_v1alpha1_rayjob.yaml. However, since this field is new and not present in the CRD of kuberay/operator:v0.5.0, it would compromise backwards compatibility.

We need to ensure that sample files function with both the 0.5.0 and nightly versions, so we shouldn't add suspend: false now, but only after the 0.6.0 release.

The failure can be reproduced:

  1. introducing suspend: false will cause the Sample YAML Config Test - 2.4.0 to consistently fail :
error: error validating "/home/runner/work/kuberay/kuberay/ray-operator/config/samples/ray_v1alpha1_rayjob.yaml": error validating data: ValidationError(RayJob.spec): unknown field "suspend" in io.ray.v1alpha1.RayJob.spec; if you choose to ignore these errors, turn validation off with --validate=false

https://github.com/ray-project/kuberay/actions/runs/4995614782/jobs/8947869834
https://github.com/ray-project/kuberay/actions/runs/5008264539/jobs/8976078708

  1. current ray_v1alpha1_rayjob.yaml is not compatible with kuberay/operator:v0.5.0.
kind delete cluster
kind create cluster --image=kindest/node:v1.24.0
helm install kuberay-operator kuberay/kuberay-operator --version 0.5.0
kubectl apply -f kuberay/ray-operator/config/samples/ray_v1alpha1_rayjob.yaml
error: error validating "/home/ubuntu/workspace/kuberay/ray-operator/config/samples/ray_v1alpha1_rayjob.yaml": error validating data: ValidationError(RayJob.spec): unknown field "suspend" in io.ray.v1alpha1.RayJob.spec; if you choose to ignore these errors, turn validation off with --validate=false

This PR removes suspend: false, so that:

  1. ray_v1alpha1_rayjob.yaml compatible with kuberay/operator:v0.5.0.
  2. ray_v1alpha1_rayjob.yaml compatible with nightly kuberay. This is becasue suspend field is optional and if not set, it will be false by default.

TODO

Add suspend: false back after 0.6.0 release.

Related issue number

Checks

  • I've made sure the tests are passing.
  • Testing Strategy
    • Unit tests
    • Manual tests
    • This PR is not tested :(

Signed-off-by: Yicheng-Lu-llll <51814063+Yicheng-Lu-llll@users.noreply.github.com>
@Yicheng-Lu-llll Yicheng-Lu-llll changed the title [bug] Sample YAML Config Test - 2.4.0 fails Fix for Sample YAML Config Test - 2.4.0 Failure due to 'suspend' Field May 18, 2023
@kevin85421 kevin85421 mentioned this pull request May 18, 2023
2 tasks
Copy link
Member

@kevin85421 kevin85421 left a comment

Choose a reason for hiding this comment

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

LGTM

@architkulkarni architkulkarni self-assigned this May 18, 2023
@kevin85421
Copy link
Member

Could you also check why the CI cannot catch this bug occasionally? Thanks!

@kevin85421
Copy link
Member

Merge this PR, but we should still figure out why CI cannot always catch this bug.

@kevin85421 kevin85421 merged commit c9665df into ray-project:master May 29, 2023
17 checks passed
lowang-bh pushed a commit to lowang-bh/kuberay that referenced this pull request Sep 24, 2023
ray-project#1096)

Fix for Sample YAML Config Test - 2.4.0 Failure due to 'suspend' Field
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants