File tree Expand file tree Collapse file tree 1 file changed +6
-7
lines changed
ads/jobs/builders/infrastructure Expand file tree Collapse file tree 1 file changed +6
-7
lines changed Original file line number Diff line number Diff line change @@ -376,13 +376,12 @@ def delete(self, force_delete: bool = False) -> DSCJob:
376
376
"""
377
377
runs = self .run_list ()
378
378
for run in runs :
379
- if force_delete :
380
- if run .lifecycle_state in [
381
- DataScienceJobRun .LIFECYCLE_STATE_ACCEPTED ,
382
- DataScienceJobRun .LIFECYCLE_STATE_IN_PROGRESS ,
383
- DataScienceJobRun .LIFECYCLE_STATE_NEEDS_ATTENTION ,
384
- ]:
385
- run .cancel (wait_for_completion = True )
379
+ if force_delete and run .lifecycle_state in [
380
+ DataScienceJobRun .LIFECYCLE_STATE_ACCEPTED ,
381
+ DataScienceJobRun .LIFECYCLE_STATE_IN_PROGRESS ,
382
+ DataScienceJobRun .LIFECYCLE_STATE_NEEDS_ATTENTION ,
383
+ ]:
384
+ run .cancel (wait_for_completion = True )
386
385
run .delete ()
387
386
self .client .delete_job (self .id )
388
387
return self
You can’t perform that action at this time.
0 commit comments