# Error msg when running dask example

**URL:** https://discuss.ray.io/t/error-msg-when-running-dask-example/1293
**Category:** Ray Core
**Created:** [March 17, 2021, 12:59pm UTC](https://discuss.ray.io/t/error-msg-when-running-dask-example/1293 "2021-03-17T12:59:51Z")
**Posts on this page:** 7
**Page:** 1

<div class="post-metadata">

### Author: ![mbehrendt](https://sea2.discourse-cdn.com/flex020/user_avatar/discuss.ray.io/mbehrendt/32/516_2.png) [@mbehrendt](https://discuss.ray.io/u/mbehrendt)
#### Post date: [March 17, 2021, 12:59pm UTC](https://discuss.ray.io/t/error-msg-when-running-dask-example/1293/1 "2021-03-17T12:59:51Z")

</div>

When just blindly following the instructions here, to execute the example in the ‘scheduler section’, i’m getting the following error msg:

[https://docs.ray.io/en/master/dask-on-ray.html](https://docs.ray.io/en/master/dask-on-ray.html)

```auto
Traceback (most recent call last):
  File "/home/ray/daskhw.py", line 24, in <module>
    df = dd.from_pandas(pd.DataFrame(np.random.randint(0, 100, size=(1024, 2)), columns=["age", "grade"]))
  File "/home/ray/anaconda3/lib/python3.7/site-packages/dask/dataframe/io/io.py", line 208, in from_pandas
    raise ValueError("Exactly one of npartitions and chunksize must be specified.")
ValueError: Exactly one of npartitions and chunksize must be specified.
command terminated with exit code 1

```

---

<div class="post-metadata">

### Author: ![Dmitri](https://sea2.discourse-cdn.com/flex020/user_avatar/discuss.ray.io/dmitri/32/657_2.png) [@Dmitri](https://discuss.ray.io/u/Dmitri)
#### Post date: [March 17, 2021, 3:24pm UTC](https://discuss.ray.io/t/error-msg-when-running-dask-example/1293/2 "2021-03-17T15:24:12Z")

</div>

cc @Stephanie_Wang @Clark_Zinzow

---

<div class="post-metadata">

### Author: ![Clark\_Zinzow](https://sea2.discourse-cdn.com/flex020/user_avatar/discuss.ray.io/clark_zinzow/32/445_2.png) [@Clark\_Zinzow](https://discuss.ray.io/u/Clark_Zinzow)
#### Post date: [March 17, 2021, 4:28pm UTC](https://discuss.ray.io/t/error-msg-when-running-dask-example/1293/3 "2021-03-17T16:28:43Z")

</div>

I have a [PR](https://github.com/ray-project/ray/pull/14461) that’s been open for a few weeks that fixes the examples in the docs, but we got hung up on getting the example to run in the CI via Sphinx, which turned out to be less trivial than when I’ve done it in the past. @sangcho since I don’t have the bandwidth to get into Sphinx stuff right now, can we merge that PR so the examples are fixed in the docs and make another task for running these examples (and others) in the CI?

---

<div class="post-metadata">

### Author: ![sangcho](https://sea2.discourse-cdn.com/flex020/user_avatar/discuss.ray.io/sangcho/32/425_2.png) [@sangcho](https://discuss.ray.io/u/sangcho)
#### Post date: [March 17, 2021, 5:38pm UTC](https://discuss.ray.io/t/error-msg-when-running-dask-example/1293/4 "2021-03-17T17:38:12Z")

</div>

The PR is merged. Please add a task to backlog so that you won’t forget about it! Also @mbehrendt please check the PR to see what code needs to be modified :)! Sorry for the hustle!

---

<div class="post-metadata">

### Author: ![Clark\_Zinzow](https://sea2.discourse-cdn.com/flex020/user_avatar/discuss.ray.io/clark_zinzow/32/445_2.png) [@Clark\_Zinzow](https://discuss.ray.io/u/Clark_Zinzow)
#### Post date: [March 18, 2021, 1:45pm UTC](https://discuss.ray.io/t/error-msg-when-running-dask-example/1293/5 "2021-03-18T13:45:18Z")

</div>

@sangcho can do! Also @mbehrendt the master docs have been updated and the Dask-on-Ray examples should now run correctly: [Dask on Ray — Ray v2.0.0.dev0](https://docs.ray.io/en/master/dask-on-ray.html)

---

<div class="post-metadata">

### Author: ![Clark\_Zinzow](https://sea2.discourse-cdn.com/flex020/user_avatar/discuss.ray.io/clark_zinzow/32/445_2.png) [@Clark\_Zinzow](https://discuss.ray.io/u/Clark_Zinzow)
#### Post date: [March 18, 2021, 1:53pm UTC](https://discuss.ray.io/t/error-msg-when-running-dask-example/1293/6 "2021-03-18T13:53:14Z")

</div>

@sangcho I added an issue for doing this for all of the data processing example code, in one sweep. [[Core - docs] Run data processing examples in CI · Issue #14769 · ray-project/ray · GitHub](https://github.com/ray-project/ray/issues/14769)

---

<div class="post-metadata">

### Author: ![mbehrendt](https://sea2.discourse-cdn.com/flex020/user_avatar/discuss.ray.io/mbehrendt/32/516_2.png) [@mbehrendt](https://discuss.ray.io/u/mbehrendt)
#### Post date: [March 18, 2021, 2:11pm UTC](https://discuss.ray.io/t/error-msg-when-running-dask-example/1293/7 "2021-03-18T14:11:37Z")

</div>

great – thank you! I validated it and it worked
