Skip to content

Commit

Permalink
fix build - only install mujoco for python 3.6, 3.7, (#2133)
Browse files Browse the repository at this point in the history
* reverting to older version of 3.6 python to test if the build is failing because of that

* revert 3.7 to 3.7.3 for the build

* revert python 3.8 version to 3.8.1

* do not install mujoco on 3.8 and 3.9

* enable mujoco for 3.7

* .

* .

* .

* use regex to navigate python version dependent package installation

* .
  • Loading branch information
pzhokhov authored Dec 18, 2020
1 parent bdf95c1 commit 1e5f770
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 6 deletions.
6 changes: 3 additions & 3 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,8 @@ python:
services:
- docker
env:
- PY_VER=3.6.12
- PY_VER=3.7.9
- PY_VER=3.6.8
- PY_VER=3.7.3
- PY_VER=3.8.6
- PY_VER=3.9.0

Expand All @@ -21,4 +21,4 @@ deploy:
password: $TWINE_PASSWORD
on:
tags: true
condition: $PY_VER = 3.6.12
condition: $PY_VER = 3.6.8
4 changes: 2 additions & 2 deletions py.Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -9,8 +9,8 @@ RUN \
curl -O https://www.roboti.us/download/mjpro150_linux.zip && \
unzip mjpro150_linux.zip

ARG MUJOCO_KEY
ARG PYTHON_VER
ARG MUJOCO_KEY
ENV MUJOCO_KEY=$MUJOCO_KEY

ENV LD_LIBRARY_PATH=$LD_LIBRARY_PATH:/root/.mujoco/mjpro150/bin
Expand All @@ -19,7 +19,7 @@ RUN pip install pytest pytest-forked lz4

COPY . /usr/local/gym/
WORKDIR /usr/local/gym/
RUN pip install .[all]
RUN bash -c "[[ $PYTHON_VER =~ 3\.[6-7]\.[0-9] ]] && pip install -e .[all] || pip install -e .[nomujoco]"

ENTRYPOINT ["/usr/local/gym/bin/docker_entrypoint"]
CMD ["pytest","--forked"]
3 changes: 2 additions & 1 deletion setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,8 @@
}

# Meta dependency groups.
extras['all'] = [item for group in extras.values() for item in group]
extras['nomujoco'] = list(set([item for name, group in extras.items() if name != 'mujoco' and name != "robotics" for item in group]))
extras['all'] = list(set([item for group in extras.values() for item in group]))

setup(name='gym',
version=VERSION,
Expand Down

0 comments on commit 1e5f770

Please sign in to comment.