def save_subworkflow(self, workflow: Workflow) -> None: """Save the DAG and inputs of the sub-workflow. Args: workflow: A sub-workflow. Could be a nested workflow inside a workflow step. """ assert not workflow.executed for w in workflow.iter_workflows_in_dag(): self._write_step_inputs(w.id, w.get_inputs())
def save_subworkflow(self, workflow: Workflow) -> None: """Save the DAG and inputs of the sub-workflow. Args: workflow: A sub-workflow. Could be a nested workflow inside a workflow step. """ assert not workflow.executed tasks = [ self._write_step_inputs(w.id, w.data) for w in workflow.iter_workflows_in_dag() ] asyncio_run(asyncio.gather(*tasks))