Skip to content

Commit

Permalink
fixup! Remove recursion in task spec
Browse files Browse the repository at this point in the history
  • Loading branch information
fjetter committed Nov 4, 2024
1 parent cfd7c4f commit 32e1349
Showing 1 changed file with 1 addition and 10 deletions.
11 changes: 1 addition & 10 deletions distributed/shuffle/_core.py
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@
from tornado.ioloop import IOLoop

import dask.config
from dask._task_spec import Task, _inline_recursively
from dask._task_spec import Task
from dask.core import flatten
from dask.sizeof import sizeof
from dask.typing import Key
Expand Down Expand Up @@ -609,15 +609,6 @@ def __sizeof__(self) -> int:
def __repr__(self) -> str:
return f"P2PBarrierTask({self.key!r})"

def inline(self, dsk: dict[Key, Any]) -> P2PBarrierTask:
self.unpack()
new_args = _inline_recursively(self.args, dsk)
new_kwargs = _inline_recursively(self.kwargs, dsk)
assert self.func is not None
return P2PBarrierTask(
self.key, self.func, *new_args, spec=self.spec, **new_kwargs
)

def __getstate__(self) -> dict[str, Any]:
state = super().__getstate__()
state["spec"] = self.spec
Expand Down

0 comments on commit 32e1349

Please sign in to comment.