From a980e10744e5539ced1d7da650b680a204868a1f Mon Sep 17 00:00:00 2001 From: Jiaming Yuan Date: Wed, 7 Dec 2022 23:25:05 +0800 Subject: [PATCH] Properly await async method client.wait_for_workers (#8558) (#8567) * Properly await async method client.wait_for_workers * ignore mypy error. Co-authored-by: jiamingy Co-authored-by: Matthew Rocklin --- python-package/xgboost/dask.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/python-package/xgboost/dask.py b/python-package/xgboost/dask.py index 7d21ff9fcb48..69d1832f1506 100644 --- a/python-package/xgboost/dask.py +++ b/python-package/xgboost/dask.py @@ -853,7 +853,7 @@ async def _get_rabit_args( sched_addr = None # make sure all workers are online so that we can obtain reliable scheduler_info - client.wait_for_workers(n_workers) + await client.wait_for_workers(n_workers) # type: ignore env = await client.run_on_scheduler( _start_tracker, n_workers, sched_addr, user_addr )