Skip to content

Commit

Permalink
Preinstall ray[rllib]<2.3 to avoid installing gym>0.21
Browse files Browse the repository at this point in the history
- Update github workflows
- Update install doc ("troubleshooting" section)
  • Loading branch information
nhuet authored and fteicht committed Sep 12, 2023
1 parent bd2006f commit 1b57128
Show file tree
Hide file tree
Showing 3 changed files with 24 additions and 9 deletions.
15 changes: 11 additions & 4 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -427,8 +427,10 @@ jobs:
python -m pip install "pip==22" # starting with pip 23.1, gym 0.21.0 is not intallable anymore
python -m pip uninstall -y wheel # wheel must not be here to fall back directly to python setup.py
python -m pip install gym==0.21.0 --no-use-pep517
# install remaining dependencies
# preinstall ray[rllib]<2.3.0 because starting from 2.3.0, ray also install gym > 0.21
python -m pip install --upgrade pip
python -m pip install "ray[rllib]<2.3.0"
# install remaining dependencies
python -m pip install pytest
- name: Download artifacts
Expand Down Expand Up @@ -514,8 +516,10 @@ jobs:
python -m pip install "pip==22" # starting with pip 23.1, gym 0.21.0 is not intallable anymore
python -m pip uninstall -y wheel # wheel must not be here to fall back directly to python setup.py
python -m pip install gym==0.21.0 --no-use-pep517
# install remaining dependencies
# preinstall ray[rllib]<2.3.0 because starting from 2.3.0, ray also install gym > 0.21
python -m pip install --upgrade pip
python -m pip install "ray[rllib]<2.3.0"
# install remaining dependencies
python -m pip install pytest
- name: Download artifacts
Expand Down Expand Up @@ -601,8 +605,10 @@ jobs:
python -m pip install "pip==22" # starting with pip 23.1, gym 0.21.0 is not intallable anymore
python -m pip uninstall -y wheel # wheel must not be here to fall back directly to python setup.py
python -m pip install gym==0.21.0 --no-use-pep517
# install remaining dependencies
# preinstall ray[rllib]<2.3.0 because starting from 2.3.0, ray also install gym > 0.21
python -m pip install --upgrade pip
python -m pip install "ray[rllib]<2.3.0"
# install remaining dependencies
python -m pip install pytest docopt commonmark
- name: Download artifacts
Expand Down Expand Up @@ -720,8 +726,9 @@ jobs:
python -m pip install "pip==22" # starting with pip 23.1, gym 0.21.0 is not intallable anymore
python -m pip uninstall -y wheel # wheel must not be here to fall back directly to python setup.py
python -m pip install gym==0.21.0 --no-use-pep517
# upgrade pip
# preinstall ray[rllib]<2.3.0 because starting from 2.3.0, ray also install gym > 0.21
python -m pip install --upgrade pip
python -m pip install "ray[rllib]<2.3.0"
# find proper wheel and install it
python_version=${{ matrix.python-version }}
wheelfile=$(ls ./wheels/scikit_decide*-cp${python_version/\./}-*manylinux*.whl)
Expand Down
15 changes: 11 additions & 4 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -344,8 +344,10 @@ jobs:
python -m pip install "pip==22" # starting with pip 23.1, gym 0.21.0 is not intallable anymore
python -m pip uninstall -y wheel # wheel must not be here to fall back directly to python setup.py
python -m pip install gym==0.21.0 --no-use-pep517
# install remaining dependencies
# preinstall ray[rllib]<2.3.0 because starting from 2.3.0, ray also install gym > 0.21
python -m pip install --upgrade pip
python -m pip install "ray[rllib]<2.3.0"
# install remaining dependencies
python -m pip install pytest
- name: Download artifacts
Expand Down Expand Up @@ -431,8 +433,10 @@ jobs:
python -m pip install "pip==22" # starting with pip 23.1, gym 0.21.0 is not intallable anymore
python -m pip uninstall -y wheel # wheel must not be here to fall back directly to python setup.py
python -m pip install gym==0.21.0 --no-use-pep517
# install remaining dependencies
# preinstall ray[rllib]<2.3.0 because starting from 2.3.0, ray also install gym > 0.21
python -m pip install --upgrade pip
python -m pip install "ray[rllib]<2.3.0"
# install remaining dependencies
python -m pip install pytest
- name: Download artifacts
Expand Down Expand Up @@ -517,8 +521,10 @@ jobs:
python -m pip install "pip==22" # starting with pip 23.1, gym 0.21.0 is not intallable anymore
python -m pip uninstall -y wheel # wheel must not be here to fall back directly to python setup.py
python -m pip install gym==0.21.0 --no-use-pep517
# install remaining dependencies
# preinstall ray[rllib]<2.3.0 because starting from 2.3.0, ray also install gym > 0.21
python -m pip install --upgrade pip
python -m pip install "ray[rllib]<2.3.0"
# install remaining dependencies
python -m pip install pytest
- name: Download artifacts
Expand Down Expand Up @@ -700,8 +706,9 @@ jobs:
python -m pip install "pip==22" # starting with pip 23.1, gym 0.21.0 is not intallable anymore
python -m pip uninstall -y wheel # wheel must not be here to fall back directly to python setup.py
python -m pip install gym==0.21.0 --no-use-pep517
# upgrade pip
# preinstall ray[rllib]<2.3.0 because starting from 2.3.0, ray also install gym > 0.21
python -m pip install --upgrade pip
python -m pip install "ray[rllib]<2.3.0"
# find proper wheel and install it
python_version=${{ env.python_version }}
wheelfile=$(ls ./wheels/scikit_decide*-cp${python_version/\./}-*manylinux*.whl)
Expand Down
3 changes: 2 additions & 1 deletion docs/install.md
Original file line number Diff line number Diff line change
Expand Up @@ -133,8 +133,9 @@ The solution is to install it beforehand:
python -m pip install "pip==22" # starting with pip 23.1, gym 0.21.0 is not intallable anymore
python -m pip uninstall -y wheel # wheel must not be here to fall back directly to python setup.py
python -m pip install gym==0.21.0 --no-use-pep517
# upgrade pip
# preinstall ray[rllib]<2.3.0 because starting from 2.3.0, ray also install gym > 0.21
python -m pip install --upgrade pip
python -m pip install "ray[rllib]<2.3.0"
# install scikit-decide and remaining dependencies
pip install -U scikit-decide[all]
```
Expand Down

0 comments on commit 1b57128

Please sign in to comment.