diff --git a/client/starwhale/core/job/model.py b/client/starwhale/core/job/model.py index 0dc0a4cbe0..ea2fabff68 100644 --- a/client/starwhale/core/job/model.py +++ b/client/starwhale/core/job/model.py @@ -169,6 +169,7 @@ def execute(self) -> TaskResult: # The standard implementation does not return results func() except Exception as e: + logger.exception(e) self.exception = e self.status = STATUS.FAILED else: diff --git a/client/starwhale/core/job/scheduler.py b/client/starwhale/core/job/scheduler.py index f68b374d1f..b6bb0400b2 100644 --- a/client/starwhale/core/job/scheduler.py +++ b/client/starwhale/core/job/scheduler.py @@ -80,6 +80,13 @@ def schedule(self) -> t.List[StepResult]: if indegree_dict[v_to] == 0: prepared_vertices.add(v_to) + if not all( + [ + all(tr.status == STATUS.SUCCESS for tr in sr.task_results) + for sr in step_results + ] + ): + break return _results def schedule_single_step(self, step_name: str) -> StepResult: