From c062158f1d5efd22d8cf2dfa6e6f1cc9f5d22641 Mon Sep 17 00:00:00 2001 From: Tom White Date: Wed, 14 Feb 2024 16:29:57 +0000 Subject: [PATCH] Remove unused `array_names` parameter in executors --- cubed/core/array.py | 1 - cubed/core/plan.py | 2 -- cubed/runtime/executors/beam.py | 4 +--- cubed/runtime/executors/coiled.py | 1 - cubed/runtime/executors/dask_distributed_async.py | 3 --- cubed/runtime/executors/lithops.py | 3 --- cubed/runtime/executors/modal.py | 3 --- cubed/runtime/executors/modal_async.py | 3 --- cubed/runtime/executors/python.py | 1 - cubed/runtime/executors/python_async.py | 3 --- 10 files changed, 1 insertion(+), 23 deletions(-) diff --git a/cubed/core/array.py b/cubed/core/array.py index 732af0d1..fdbd52fb 100644 --- a/cubed/core/array.py +++ b/cubed/core/array.py @@ -286,7 +286,6 @@ def compute( optimize_graph=optimize_graph, optimize_function=optimize_function, resume=resume, - array_names=[a.name for a in arrays], spec=spec, **kwargs, ) diff --git a/cubed/core/plan.py b/cubed/core/plan.py index ce619fd8..508835ec 100644 --- a/cubed/core/plan.py +++ b/cubed/core/plan.py @@ -193,7 +193,6 @@ def execute( optimize_function=None, resume=None, spec=None, - array_names=None, **kwargs, ): dag = self._finalize_dag(optimize_graph, optimize_function) @@ -204,7 +203,6 @@ def execute( executor.execute_dag( dag, callbacks=callbacks, - array_names=array_names, resume=resume, spec=spec, **kwargs, diff --git a/cubed/runtime/executors/beam.py b/cubed/runtime/executors/beam.py index fd919c0c..8db7b3b3 100644 --- a/cubed/runtime/executors/beam.py +++ b/cubed/runtime/executors/beam.py @@ -82,9 +82,7 @@ def expand(self, pcoll): class BeamDagExecutor(DagExecutor): """An execution engine that uses Apache Beam.""" - def execute_dag( - self, dag, callbacks=None, array_names=None, resume=None, spec=None, **kwargs - ): + def execute_dag(self, dag, callbacks=None, resume=None, spec=None, **kwargs): dag = dag.copy() pipeline = beam.Pipeline(**kwargs) diff --git a/cubed/runtime/executors/coiled.py b/cubed/runtime/executors/coiled.py index c60b63c1..00cea4bf 100644 --- a/cubed/runtime/executors/coiled.py +++ b/cubed/runtime/executors/coiled.py @@ -20,7 +20,6 @@ def execute_dag( self, dag: MultiDiGraph, callbacks: Optional[Sequence[Callback]] = None, - array_names: Optional[Sequence[str]] = None, resume: Optional[bool] = None, spec: Optional[Spec] = None, **coiled_kwargs: Mapping[str, Any], diff --git a/cubed/runtime/executors/dask_distributed_async.py b/cubed/runtime/executors/dask_distributed_async.py index 5a452a16..b6f1a10c 100644 --- a/cubed/runtime/executors/dask_distributed_async.py +++ b/cubed/runtime/executors/dask_distributed_async.py @@ -110,7 +110,6 @@ def check_runtime_memory(spec, client): async def async_execute_dag( dag: MultiDiGraph, callbacks: Optional[Sequence[Callback]] = None, - array_names: Optional[Sequence[str]] = None, resume: Optional[bool] = None, spec: Optional[Spec] = None, compute_arrays_in_parallel: Optional[bool] = None, @@ -151,7 +150,6 @@ def execute_dag( self, dag: MultiDiGraph, callbacks: Optional[Sequence[Callback]] = None, - array_names: Optional[Sequence[str]] = None, resume: Optional[bool] = None, spec: Optional[Spec] = None, compute_kwargs: Optional[Dict[str, Any]] = None, @@ -162,7 +160,6 @@ def execute_dag( async_execute_dag( dag, callbacks=callbacks, - array_names=array_names, resume=resume, spec=spec, compute_kwargs=compute_kwargs, diff --git a/cubed/runtime/executors/lithops.py b/cubed/runtime/executors/lithops.py index 9bd71529..905476c8 100644 --- a/cubed/runtime/executors/lithops.py +++ b/cubed/runtime/executors/lithops.py @@ -160,7 +160,6 @@ def map_unordered( def execute_dag( dag: MultiDiGraph, callbacks: Optional[Sequence[Callback]] = None, - array_names: Optional[Sequence[str]] = None, resume: Optional[bool] = None, spec: Optional[Spec] = None, compute_arrays_in_parallel: Optional[bool] = None, @@ -241,7 +240,6 @@ def execute_dag( self, dag: MultiDiGraph, callbacks: Optional[Sequence[Callback]] = None, - array_names: Optional[Sequence[str]] = None, resume: Optional[bool] = None, spec: Optional[Spec] = None, **kwargs, @@ -250,7 +248,6 @@ def execute_dag( execute_dag( dag, callbacks=callbacks, - array_names=array_names, resume=resume, spec=spec, **merged_kwargs, diff --git a/cubed/runtime/executors/modal.py b/cubed/runtime/executors/modal.py index c00f2057..55721954 100644 --- a/cubed/runtime/executors/modal.py +++ b/cubed/runtime/executors/modal.py @@ -112,7 +112,6 @@ def run_remotely(self, input, func=None, config=None): def execute_dag( dag: MultiDiGraph, callbacks: Optional[Sequence[Callback]] = None, - array_names: Optional[Sequence[str]] = None, resume: Optional[bool] = None, spec: Optional[Spec] = None, cloud: Optional[str] = None, @@ -151,7 +150,6 @@ def execute_dag( self, dag: MultiDiGraph, callbacks: Optional[Sequence[Callback]] = None, - array_names: Optional[Sequence[str]] = None, resume: Optional[bool] = None, spec: Optional[Spec] = None, **kwargs, @@ -160,7 +158,6 @@ def execute_dag( execute_dag( dag, callbacks=callbacks, - array_names=array_names, resume=resume, spec=spec, **merged_kwargs, diff --git a/cubed/runtime/executors/modal_async.py b/cubed/runtime/executors/modal_async.py index 4bd579ca..68bd60d4 100644 --- a/cubed/runtime/executors/modal_async.py +++ b/cubed/runtime/executors/modal_async.py @@ -108,7 +108,6 @@ def pipeline_to_stream(app_function, name, pipeline, **kwargs): async def async_execute_dag( dag: MultiDiGraph, callbacks: Optional[Sequence[Callback]] = None, - array_names: Optional[Sequence[str]] = None, resume: Optional[bool] = None, spec: Optional[Spec] = None, cloud: Optional[str] = None, @@ -155,7 +154,6 @@ def execute_dag( self, dag: MultiDiGraph, callbacks: Optional[Sequence[Callback]] = None, - array_names: Optional[Sequence[str]] = None, resume: Optional[bool] = None, spec: Optional[Spec] = None, **kwargs, @@ -165,7 +163,6 @@ def execute_dag( async_execute_dag( dag, callbacks=callbacks, - array_names=array_names, resume=resume, spec=spec, **merged_kwargs, diff --git a/cubed/runtime/executors/python.py b/cubed/runtime/executors/python.py index 4edfeb37..d8083bef 100644 --- a/cubed/runtime/executors/python.py +++ b/cubed/runtime/executors/python.py @@ -18,7 +18,6 @@ def execute_dag( self, dag: MultiDiGraph, callbacks: Optional[Sequence[Callback]] = None, - array_names: Optional[Sequence[str]] = None, resume: Optional[bool] = None, spec: Optional[Spec] = None, **kwargs, diff --git a/cubed/runtime/executors/python_async.py b/cubed/runtime/executors/python_async.py index f0dc73db..53ca4daf 100644 --- a/cubed/runtime/executors/python_async.py +++ b/cubed/runtime/executors/python_async.py @@ -82,7 +82,6 @@ def pipeline_to_stream( async def async_execute_dag( dag: MultiDiGraph, callbacks: Optional[Sequence[Callback]] = None, - array_names: Optional[Sequence[str]] = None, resume: Optional[bool] = None, spec: Optional[Spec] = None, compute_arrays_in_parallel: Optional[bool] = None, @@ -125,7 +124,6 @@ def execute_dag( self, dag: MultiDiGraph, callbacks: Optional[Sequence[Callback]] = None, - array_names: Optional[Sequence[str]] = None, resume: Optional[bool] = None, spec: Optional[Spec] = None, **kwargs, @@ -134,7 +132,6 @@ def execute_dag( async_execute_dag( dag, callbacks=callbacks, - array_names=array_names, resume=resume, spec=spec, **kwargs,