mirror of
https://github.com/Farama-Foundation/Gymnasium.git
synced 2025-08-01 06:07:08 +00:00
Remove Python 3.5 support, travis and setup.py maintenance (#2084)
* remove python 3.5, update travis * add travis * add cmake during tests * add swig * disable python 3.8 removal? * remove depricated failover * add opencv and pillow minimum versions * try removing pillow minimum version * try older version of ubuntu * reup ubuntu * make pillow version suitable for pyglet version range * remove extraneous run * rerun stalled CI
This commit is contained in:
12
.travis.yml
12
.travis.yml
@@ -1,15 +1,13 @@
|
||||
dist: xenial
|
||||
dist: focal
|
||||
language: python
|
||||
python:
|
||||
- "3.7"
|
||||
services:
|
||||
- docker
|
||||
env:
|
||||
- PY_VER=3.5.6
|
||||
- PY_VER=3.6.8
|
||||
- PY_VER=3.7.3
|
||||
- PY_VER=3.8.1
|
||||
|
||||
- PY_VER=3.6.12
|
||||
- PY_VER=3.7.9
|
||||
- PY_VER=3.8.6
|
||||
|
||||
install: "" # so travis doesn't do pip install requirements.txt
|
||||
script:
|
||||
@@ -22,4 +20,4 @@ deploy:
|
||||
password: $TWINE_PASSWORD
|
||||
on:
|
||||
tags: true
|
||||
condition: $PY_VER = 3.5.6
|
||||
condition: $PY_VER = 3.6.12
|
||||
|
@@ -300,10 +300,7 @@ class ImageEncoder(object):
|
||||
if frame.dtype != np.uint8:
|
||||
raise error.InvalidFrame("Your frame has data type {}, but we require uint8 (i.e. RGB values from 0-255).".format(frame.dtype))
|
||||
|
||||
if distutils.version.LooseVersion(np.__version__) >= distutils.version.LooseVersion('1.9.0'):
|
||||
self.proc.stdin.write(frame.tobytes())
|
||||
else:
|
||||
self.proc.stdin.write(frame.tostring())
|
||||
|
||||
def close(self):
|
||||
self.proc.stdin.close()
|
||||
|
@@ -1,7 +1,7 @@
|
||||
# A Dockerfile that sets up a full Gym install with test dependencies
|
||||
ARG PYTHON_VER
|
||||
FROM python:$PYTHON_VER
|
||||
RUN apt-get -y update && apt-get install -y unzip libglu1-mesa-dev libgl1-mesa-dev libosmesa6-dev xvfb patchelf ffmpeg
|
||||
RUN apt-get -y update && apt-get install -y unzip libglu1-mesa-dev libgl1-mesa-dev libosmesa6-dev xvfb patchelf ffmpeg cmake swig
|
||||
RUN \
|
||||
# Download mujoco
|
||||
mkdir /root/.mujoco && \
|
||||
@@ -19,7 +19,7 @@ RUN pip install pytest pytest-forked lz4
|
||||
|
||||
COPY . /usr/local/gym/
|
||||
WORKDIR /usr/local/gym/
|
||||
RUN [ "$PYTHON_VER" != "3.8.1" ] && pip install .[all] || pip install .
|
||||
RUN pip install .[all]
|
||||
|
||||
ENTRYPOINT ["/usr/local/gym/bin/docker_entrypoint"]
|
||||
CMD ["pytest","--forked"]
|
||||
|
7
setup.py
7
setup.py
@@ -7,7 +7,7 @@ from version import VERSION
|
||||
|
||||
# Environment-specific dependencies.
|
||||
extras = {
|
||||
'atari': ['atari_py~=0.2.0', 'Pillow', 'opencv-python'],
|
||||
'atari': ['atari_py~=0.2.0', 'opencv-python>=3.'],
|
||||
'box2d': ['box2d-py~=2.3.5'],
|
||||
'classic_control': [],
|
||||
'mujoco': ['mujoco_py>=1.50, <2.0', 'imageio'],
|
||||
@@ -28,7 +28,7 @@ setup(name='gym',
|
||||
if package.startswith('gym')],
|
||||
zip_safe=False,
|
||||
install_requires=[
|
||||
'scipy', 'numpy>=1.10.4', 'pyglet>=1.4.0,<=1.5.0', 'cloudpickle>=1.2.0,<1.7.0',
|
||||
'scipy', 'numpy>=1.10.4', 'pyglet>=1.4.0,<=1.5.0', 'Pillow<=7.2.0', 'cloudpickle>=1.2.0,<1.7.0',
|
||||
],
|
||||
extras_require=extras,
|
||||
package_data={'gym': [
|
||||
@@ -42,10 +42,9 @@ setup(name='gym',
|
||||
'envs/robotics/assets/textures/*.png']
|
||||
},
|
||||
tests_require=['pytest', 'mock'],
|
||||
python_requires='>=3.5',
|
||||
python_requires='>=3.6',
|
||||
classifiers=[
|
||||
'Programming Language :: Python :: 3',
|
||||
'Programming Language :: Python :: 3.5',
|
||||
'Programming Language :: Python :: 3.6',
|
||||
'Programming Language :: Python :: 3.7',
|
||||
'Programming Language :: Python :: 3.8',
|
||||
|
Reference in New Issue
Block a user