You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
returnfmt.Errorf("the DeletionPolicyType field of DeletionStrategy.OnSuccess cannot be unset when DeletionStrategy is enabled")
233
+
returnfmt.Errorf("The RayJob spec is invalid: the DeletionPolicyType field of DeletionStrategy.OnSuccess cannot be unset when DeletionStrategy is enabled")
234
234
}
235
235
ifonFailurePolicy.Policy==nil {
236
-
returnfmt.Errorf("the DeletionPolicyType field of DeletionStrategy.OnFailure cannot be unset when DeletionStrategy is enabled")
236
+
returnfmt.Errorf("The RayJob spec is invalid: the DeletionPolicyType field of DeletionStrategy.OnFailure cannot be unset when DeletionStrategy is enabled")
237
237
}
238
238
239
239
ifisClusterSelectorMode {
240
240
switch*onSuccessPolicy.Policy {
241
241
caserayv1.DeleteCluster:
242
-
returnfmt.Errorf("the ClusterSelector mode doesn't support DeletionStrategy=DeleteCluster on success")
242
+
returnfmt.Errorf("The RayJob spec is invalid: the ClusterSelector mode doesn't support DeletionStrategy=DeleteCluster on success")
243
243
caserayv1.DeleteWorkers:
244
-
returnfmt.Errorf("the ClusterSelector mode doesn't support DeletionStrategy=DeleteWorkers on success")
244
+
returnfmt.Errorf("The RayJob spec is invalid: the ClusterSelector mode doesn't support DeletionStrategy=DeleteWorkers on success")
245
245
}
246
246
247
247
switch*onFailurePolicy.Policy {
248
248
caserayv1.DeleteCluster:
249
-
returnfmt.Errorf("the ClusterSelector mode doesn't support DeletionStrategy=DeleteCluster on failure")
249
+
returnfmt.Errorf("The RayJob spec is invalid: the ClusterSelector mode doesn't support DeletionStrategy=DeleteCluster on failure")
250
250
caserayv1.DeleteWorkers:
251
-
returnfmt.Errorf("the ClusterSelector mode doesn't support DeletionStrategy=DeleteWorkers on failure")
251
+
returnfmt.Errorf("The RayJob spec is invalid: the ClusterSelector mode doesn't support DeletionStrategy=DeleteWorkers on failure")
252
252
}
253
253
}
254
254
255
255
if (*onSuccessPolicy.Policy==rayv1.DeleteWorkers||*onFailurePolicy.Policy==rayv1.DeleteWorkers) &&IsAutoscalingEnabled(rayJob.Spec.RayClusterSpec) {
256
256
// TODO (rueian): This can be supported in a future Ray version. We should check the RayVersion once we know it.
257
-
returnfmt.Errorf("DeletionStrategy=DeleteWorkers currently does not support RayCluster with autoscaling enabled")
257
+
returnfmt.Errorf("The RayJob spec is invalid: DeletionStrategy=DeleteWorkers currently does not support RayCluster with autoscaling enabled")
0 commit comments