From b035e82b63d9f50d449e30699d58419b79e2d77d Mon Sep 17 00:00:00 2001 From: Peter Andreas Entschev Date: Wed, 18 Jan 2023 10:52:12 -0800 Subject: [PATCH] Ensure event loop is created in `test_lock_workers` --- dask_cuda/tests/test_explicit_comms.py | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/dask_cuda/tests/test_explicit_comms.py b/dask_cuda/tests/test_explicit_comms.py index 88e1294c..e392d323 100644 --- a/dask_cuda/tests/test_explicit_comms.py +++ b/dask_cuda/tests/test_explicit_comms.py @@ -330,6 +330,12 @@ def test_lock_workers(): except ImportError as e: pytest.skip(str(e)) + # Avoids DeprecationWarning from `IOLoop()` due to no event loop getting created + # with `asyncio.get_event_loop()` in Python >= 3.10 + # TODO: Switch to async cluster, simply switching the cluster is raising connection + # errors. + asyncio.new_event_loop() + with LocalCluster( protocol="tcp", dashboard_address=None,