-
-
Notifications
You must be signed in to change notification settings - Fork 719
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Functional change for get_worker #7696
Comments
Another alternative is to add the functionality back in with a specific flag for doing so:
I think either approach should work. @fjetter if you have time can you weigh in ? |
If you are using # replace this
def foo():
get_worker().address
# with this
def foo(dask_worker):
dask_worker.address |
Looks like this is the approach you are taking in rapidsai/raft#1365 If this is not good enough for you, we can look into making Worker.run context aware. I believe the only reason was scope creep because |
I'm ok with that change, but I think this has caused some confusion, and I'm confused myself. For example, I can't run Is the above expected? Can we use |
The behavior of async functions is a bit odd nowadays. The intention is to run those in a dedicated thread as well which would fix this problem for you, see #7339 Nothing is blocking this PR other than me finding time. If this is important for you, we can push this PR over the finishing line. |
I rebased #7339 and if CI is green-ish we can merge this to fix your async submit problem. |
I looked at rapidsai/dask-cuda@884a595 and argue this "workaround" is how it is supposed to be. |
Not a problem. There are still some test failures anyhow and this is not top priority so this aligns well |
In #7580 we removed the ability for
get_worker
to return non-task worker functions to return the worker. This is a confusing statement -- essentially for the following is no longer supportedclient.run
runs functions on each worker but there is no task soget_worker
returns None. This is functionality RAPIDS folks have been using like the following:https://github.com/rapidsai/raft/blob/05d899b36b76545d2439dbe47e4659d644ced227/python/raft-dask/raft_dask/common/comms.py#L410-L414
We are fixing this by relying on the dask_worker arg for client.run functions:
We have a fix for this in Dask-CUDA and working on one for RAFT. I think we should include a statement like the following to warn legacy users of the change get_worker:
The text was updated successfully, but these errors were encountered: