Skip to content

Commit

Permalink
Add back LocalCluster.__repr__.
Browse files Browse the repository at this point in the history
LocalCluster.__repr__ was removed in dask#2675.
  • Loading branch information
lesteve committed May 29, 2019
1 parent d202e62 commit 10e1e36
Showing 1 changed file with 7 additions and 0 deletions.
7 changes: 7 additions & 0 deletions distributed/deploy/local.py
Expand Up @@ -197,6 +197,13 @@ def __init__(
)
self.scale(n_workers)

def __repr__(self):
return "LocalCluster(%r, workers=%d, ncores=%d)" % (
self.scheduler_address,
len(self.workers),
sum(w.ncores for w in self.workers.values()),
)


def nprocesses_nthreads(n):
"""
Expand Down

0 comments on commit 10e1e36

Please sign in to comment.