diff --git a/python/ray/util/dask/tests/test_dask_callback.py b/python/ray/util/dask/tests/test_dask_callback.py index 69e616ca2d58..c9e339c3dfcb 100644 --- a/python/ray/util/dask/tests/test_dask_callback.py +++ b/python/ray/util/dask/tests/test_dask_callback.py @@ -1,9 +1,15 @@ +import sys + import dask import pytest import ray from ray.util.dask import ray_dask_get, RayDaskCallback +pytestmark = pytest.mark.skipif( + sys.version_info >= (3, 12), reason="Skip dask tests for Python version 3.12+" +) + @pytest.fixture def ray_start_1_cpu(): diff --git a/python/ray/util/dask/tests/test_dask_optimization.py b/python/ray/util/dask/tests/test_dask_optimization.py index 4d8c6199a346..f6c064d50903 100644 --- a/python/ray/util/dask/tests/test_dask_optimization.py +++ b/python/ray/util/dask/tests/test_dask_optimization.py @@ -1,3 +1,5 @@ +import sys + import dask import dask.dataframe as dd from dask.dataframe.shuffle import SimpleShuffleLayer @@ -13,6 +15,10 @@ MultipleReturnSimpleShuffleLayer, ) +pytestmark = pytest.mark.skipif( + sys.version_info >= (3, 12), reason="Skip dask tests for Python version 3.12+" +) + def test_rewrite_simple_shuffle_layer(ray_start_regular_shared): npartitions = 10 diff --git a/python/ray/util/dask/tests/test_dask_scheduler.py b/python/ray/util/dask/tests/test_dask_scheduler.py index edbf86d7b50b..33e4d49dc367 100644 --- a/python/ray/util/dask/tests/test_dask_scheduler.py +++ b/python/ray/util/dask/tests/test_dask_scheduler.py @@ -14,6 +14,10 @@ from ray.util.dask import disable_dask_on_ray, enable_dask_on_ray, ray_dask_get from ray.util.dask.callbacks import ProgressBarCallback +pytestmark = pytest.mark.skipif( + sys.version_info >= (3, 12), reason="Skip dask tests for Python version 3.12+" +) + @pytest.fixture def ray_start_1_cpu(): diff --git a/python/requirements/ml/data-requirements.txt b/python/requirements/ml/data-requirements.txt index 7e2eec19351a..b8d5e4764db7 100644 --- a/python/requirements/ml/data-requirements.txt +++ b/python/requirements/ml/data-requirements.txt @@ -1,7 +1,8 @@ # Used by CI for datasets and docs. # https://github.com/ray-project/ray/pull/29448#discussion_r1006256498 -dask[complete]==2022.10.1 +dask[complete]==2022.10.1; python_version < '3.12' +dask[complete]==2024.6.0; python_version >= '3.12' aioboto3==11.2.0 crc32c==2.3 flask_cors diff --git a/python/requirements_compiled.txt b/python/requirements_compiled.txt index 3ac9df36594b..0a11396fbe05 100644 --- a/python/requirements_compiled.txt +++ b/python/requirements_compiled.txt @@ -387,7 +387,8 @@ cython==0.29.37 # via # -r /ray/ci/../python/requirements/test-requirements.txt # gpy -dask==2022.10.1 +dask==2022.10.1; python_version < '3.12' +dask==2024.6.0; python_version >= '3.12' # via # -r /ray/ci/../python/requirements/ml/data-requirements.txt # distributed @@ -425,7 +426,8 @@ dill==0.3.7 # pymoo distlib==0.3.7 # via virtualenv -distributed==2022.10.1 +distributed==2022.10.1; python_version < '3.12' +distributed==2024.6.0; python_version >= '3.12' # via dask dm-control==1.0.12 # via -r /ray/ci/../python/requirements/ml/rllib-test-requirements.txt