diff --git a/docs/requirements-doc.txt b/docs/requirements-doc.txt index 695cf7812bb..60eb5fe301b 100644 --- a/docs/requirements-doc.txt +++ b/docs/requirements-doc.txt @@ -9,6 +9,9 @@ pyyaml recommonmark sphinx sphinx-click +# Pin ray to < 1.13.0 to work around GH#4564 +# TODO(https://github.com/modin-project/modin/issues/4564): let ray go past 1.13.0. +ray[default]>=1.4.0,<1.13.0 git+https://github.com/modin-project/modin.git@master#egg=modin[all] sphinxcontrib_plantuml sphinx-issues diff --git a/environment-dev.yml b/environment-dev.yml index 6e1b904f029..a635b3f002a 100644 --- a/environment-dev.yml +++ b/environment-dev.yml @@ -41,7 +41,9 @@ dependencies: - modin-spreadsheet>=0.1.1 - tqdm - git+https://github.com/airspeed-velocity/asv.git@ef016e233cb9a0b19d517135104f49e0a3c380e9 - - ray[default]>=1.4.0 + # Pin ray to < 1.13.0 to work around GH#4564 + # TODO(https://github.com/modin-project/modin/issues/4564): let ray go past 1.13.0. + - ray[default]>=1.4.0,<1.13.0 - connectorx>=0.2.6a4 # TODO: remove when resolving GH#4398 - redis>=3.5.0,<4.0.0 diff --git a/modin/config/envvars.py b/modin/config/envvars.py index c49770c5120..d475ae906de 100644 --- a/modin/config/envvars.py +++ b/modin/config/envvars.py @@ -81,7 +81,11 @@ def _get_default(cls): ------- str """ - from modin.utils import MIN_RAY_VERSION, MIN_DASK_VERSION + from modin.utils import ( + MIN_RAY_VERSION, + MAX_RAY_VERSION_EXCLUSIVE, + MIN_DASK_VERSION, + ) if IsDebug.get(): return "Python" @@ -91,9 +95,14 @@ def _get_default(cls): except ImportError: pass else: - if version.parse(ray.__version__) < MIN_RAY_VERSION: + if ( + version.parse(ray.__version__) < MIN_RAY_VERSION + or version.parse(ray.__version__) >= MAX_RAY_VERSION_EXCLUSIVE + ): raise ImportError( - f"Please `pip install modin[ray]` to install compatible Ray version (>={MIN_RAY_VERSION})." + "Please `pip install modin[ray]` to install compatible Ray " + + "version " + + f"(>={MIN_RAY_VERSION},<{MAX_RAY_VERSION_EXCLUSIVE})." ) return "Ray" try: diff --git a/modin/utils.py b/modin/utils.py index f2a7f9d61b3..865dd5a2500 100644 --- a/modin/utils.py +++ b/modin/utils.py @@ -36,6 +36,9 @@ from modin._version import get_versions MIN_RAY_VERSION = version.parse("1.4.0") +# TODO(https://github.com/modin-project/modin/issues/4564): +# once ray can go past 1.13.0, remove this constant and stop checking it. +MAX_RAY_VERSION_EXCLUSIVE = version.parse("1.13.0") MIN_DASK_VERSION = version.parse("2.22.0") PANDAS_API_URL_TEMPLATE = f"https://pandas.pydata.org/pandas-docs/version/{pandas.__version__}/reference/api/{{}}.html" diff --git a/requirements-dev.txt b/requirements-dev.txt index 7fddfeb34c5..2495e63a3e5 100644 --- a/requirements-dev.txt +++ b/requirements-dev.txt @@ -3,7 +3,9 @@ numpy>=1.18.5 pyarrow>=4.0.1 dask[complete]>=2.22.0,<2022.2.0 distributed>=2.22.0,<2022.2.0 -ray[default]>=1.4.0 +# Pin ray to < 1.13.0 to work around GH#4564 +# TODO(https://github.com/modin-project/modin/issues/4564): let ray go past 1.13.0. +ray[default]>=1.4.0,<1.13.0 redis>=3.5.0,<4.0.0 psutil==5.6.6 fsspec diff --git a/setup.py b/setup.py index 444ee832667..6794164d375 100644 --- a/setup.py +++ b/setup.py @@ -6,7 +6,9 @@ dask_deps = ["dask>=2.22.0,<2022.2.0", "distributed>=2.22.0,<2022.2.0"] # TODO: remove redis dependency when resolving GH#4398 -ray_deps = ["ray[default]>=1.4.0", "pyarrow>=4.0.1", "redis>=3.5.0,<4.0.0"] +# Pin ray to < 1.13.0 to work around GH#4564 +# TODO(https://github.com/modin-project/modin/issues/4564): let ray go past 1.13.0. +ray_deps = ["ray[default]>=1.4.0,<1.13.0", "pyarrow>=4.0.1", "redis>=3.5.0,<4.0.0"] remote_deps = ["rpyc==4.1.5", "cloudpickle", "boto3"] spreadsheet_deps = ["modin-spreadsheet>=0.1.0"] sql_deps = ["dfsql>=0.4.2", "pyparsing<=2.4.7"]