coiled / feedback

A place to provide Coiled feedback
14 stars 3 forks source link

Clearer error when forgetting distributed in `pip=` requirements #122

Open gjoseph92 opened 3 years ago

gjoseph92 commented 3 years ago

When creating a cluster from a software environment that's missing distributed, you just get an error like cluster unexpectedly STOPPED. Going to the logs on the Coiled dashboard, I'm able to find

/opt/conda/envs/coiled/bin/python: Error while finding module specification for 'distributed.cli.dask_spec' (ModuleNotFoundError: No module named 'distributed')

But it would be nice to try-except that and display a more informative error on the client side.

I suppose it would be even nicer to catch at environment creation time—but perhaps there's a use-case for creating an environment that doesn't include distributed, only for local use?

Also, it's probably worth noting in the docs (and, better, via a warning at environment creation time) that bokeh is not included automatically either, nor is it a dependency of distributed (or dask[distributed], as recommended), so it should also be included explicitly. Seeing this and having to recreate everything was disappointing:

Dask needs bokeh >= 0.13.0 for the dashboard.

Install with conda: conda install bokeh>=0.13.0

Install with pip: pip install bokeh>=0.13.0