Skip to content

Add warning if creating scratch directories takes a long time - #2561

Merged
mrocklin merged 4 commits into
dask:masterfrom
mrocklin:warn-on-duration
Apr 8, 2019
Merged

mrocklin merged 4 commits into
dask:masterfrom
mrocklin:warn-on-duration

Conversation

@mrocklin

Copy link
Copy Markdown
Member

This adds a context manager warn_on_duration which warns if an action
takes a surprisingly long time.

We then use the context manager when creating a worker's local
directory.

Fixes rapidsai/dask-cuda#11
See also dask/dask-jobqueue#193

This adds a context manager `warn_on_duration` which warns if an action
takes a surprisingly long time.

We then use the context manager when creating a worker's local
directory.

Fixes rapidsai/dask-cuda#11
See also dask/dask-jobqueue#193

@guillaumeeb guillaumeeb left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good!

Except apparently there are more things in the warning record than you thought:

>       assert len(record) == 1
E       assert 5 == 1
E         -5
E         +1

@mrocklin
mrocklin merged commit f50b239 into dask:master Apr 8, 2019
@mrocklin
mrocklin deleted the warn-on-duration branch April 8, 2019 15:17
darindf pushed a commit to darindf/distributed that referenced this pull request Apr 11, 2019
)

This adds a context manager `warn_on_duration` which warns if an action
takes a surprisingly long time.

We then use the context manager when creating a worker's local
directory.

Fixes rapidsai/dask-cuda#11
See also dask/dask-jobqueue#193
muammar added a commit to muammar/distributed that referenced this pull request Apr 12, 2019
* upstream/master:
  Add RabbitMQ SchedulerPlugin example (dask#2604)
  add resources to scheduler update_graph plugin (dask#2603)
  Use ensure_bytes in serialize_error (dask#2588)
  Specify data storage explicitly from Worker constructor (dask#2600)
  Change bokeh port keywords to dashboard_address (dask#2589)
  .detach_() pytorch tensor to serialize data as numpy array. (dask#2586)
  Add warning if creating scratch directories takes a long time (dask#2561)
  Fix typo in pub-sub doc. (dask#2599)
  Allow return_when='FIRST_COMPLETED' in wait (dask#2598)
  Forward kwargs through Nanny to Worker (dask#2596)
@lkugler

lkugler commented Jul 23, 2019

Copy link
Copy Markdown

Hi, so one can try to use local_dir argument to LocalCluster(local_dir=...) with a directory directly on the machines harddrive?

@mrocklin

mrocklin commented Jul 23, 2019 via email

Copy link
Copy Markdown
Member Author

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Takes very long to launch all the workers.

3 participants