diff --git a/CHANGELOG.md b/CHANGELOG.md index c02f704..9185da2 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -26,6 +26,7 @@ now be installed separately through `watergrid[...]` metapackages. (#54) - Resolved issue with objects inside a `DataContext` not being copied when the output mode of a step is set to `SPLIT`. (#6) +- Pipeline now stops running if there are no more contexts to process in a new step. (#78) ### Security diff --git a/watergrid/pipelines/pipeline.py b/watergrid/pipelines/pipeline.py index e3a0e43..8fdce8b 100644 --- a/watergrid/pipelines/pipeline.py +++ b/watergrid/pipelines/pipeline.py @@ -133,6 +133,8 @@ def __run_pipeline_steps(self): contexts = [self.__generate_first_context()] for step in self._steps: contexts = self.__run_step_for_each_context(step, contexts) + if len(contexts) == 0: + break def __generate_first_context(self) -> DataContext: """