Drop python 3.7, add 3.11 and update github templates (#194)

* Update issue templates

* Update supported python versions

* Update min PyTorch version

* Skip pytype for py311

* Update conda env for doc
This commit is contained in:
Antonin RAFFIN 2023-07-03 12:45:20 +02:00 committed by GitHub
parent de92025bb2
commit 35f06254ba
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
11 changed files with 55 additions and 24 deletions

View File

@ -1,5 +1,5 @@
name: "\U0001F41B Bug Report" name: "\U0001F41B Bug Report"
description: Submit a bug report to help us improve Stable-Baselines3 Contrib description: If you encounter an unexpected behavior, software crash, or other bug.
title: "[Bug]: bug title" title: "[Bug]: bug title"
labels: ["bug"] labels: ["bug"]
body: body:
@ -67,7 +67,7 @@ body:
required: true required: true
- label: I have read the [documentation](https://sb3-contrib.readthedocs.io/en/master/) - label: I have read the [documentation](https://sb3-contrib.readthedocs.io/en/master/)
required: true required: true
- label: I have provided a minimal working example to reproduce the bug - label: I have provided a [minimal and working](https://github.com/DLR-RM/stable-baselines3/issues/982#issuecomment-1197044014) example to reproduce the bug
required: true required: true
- label: I've used the [markdown code blocks](https://help.github.com/en/articles/creating-and-highlighting-code-blocks) for both code and stack traces. - label: I've used the [markdown code blocks](https://help.github.com/en/articles/creating-and-highlighting-code-blocks) for both code and stack traces.
required: true required: true

View File

@ -1,6 +1,6 @@
name: "\U0001F916 Custom Gym Environment Issue" name: "\U0001F916 Custom Gym Environment Issue"
description: How to report an issue when using a custom Gym environment description: If your problem involves a custom gym environment.
labels: ["question", "custom gym env"] labels: ["custom gym env"]
body: body:
- type: markdown - type: markdown
attributes: attributes:
@ -28,7 +28,7 @@ body:
attributes: attributes:
label: Code example label: Code example
description: | description: |
Please try to provide a minimal example to reproduce the bug. Please try to provide a [minimal example](https://github.com/DLR-RM/stable-baselines3/issues/982#issuecomment-1197044014) to reproduce the bug.
For a custom environment, you need to give at least the observation space, action space, `reset()` and `step()` methods (see working example below). For a custom environment, you need to give at least the observation space, action space, `reset()` and `step()` methods (see working example below).
Error messages and stack traces are also helpful. Error messages and stack traces are also helpful.
Please use the [markdown code blocks](https://help.github.com/en/articles/creating-and-highlighting-code-blocks) for both code and stack traces. Please use the [markdown code blocks](https://help.github.com/en/articles/creating-and-highlighting-code-blocks) for both code and stack traces.
@ -102,7 +102,7 @@ body:
required: true required: true
- label: I have read the [documentation](https://sb3-contrib.readthedocs.io/en/master/) - label: I have read the [documentation](https://sb3-contrib.readthedocs.io/en/master/)
required: true required: true
- label: I have provided a minimal working example to reproduce the bug - label: I have provided a [minimal and working](https://github.com/DLR-RM/stable-baselines3/issues/982#issuecomment-1197044014) example to reproduce the bug
required: true required: true
- label: I have checked my env using the env checker - label: I have checked my env using the env checker
required: true required: true

View File

@ -1,5 +1,5 @@
name: "\U0001F4DA Documentation" name: "\U0001F4DA Documentation"
description: Report an issue related to Stable-Baselines3 Contrib documentation description: If you want to improve the documentation by reporting errors, inconsistencies, or missing information.
labels: ["documentation"] labels: ["documentation"]
body: body:
- type: markdown - type: markdown

View File

@ -1,5 +1,5 @@
name: "\U0001F680 Feature Request" name: "\U0001F680 Feature Request"
description: How to create an issue for requesting a feature description: If you have an idea for a new feature or an improvement.
title: "[Feature Request] request title" title: "[Feature Request] request title"
labels: ["enhancement"] labels: ["enhancement"]
body: body:
@ -42,3 +42,5 @@ body:
options: options:
- label: I have checked that there is no similar [issue](https://github.com/Stable-Baselines-Team/stable-baselines3-contrib/issues) in the repo - label: I have checked that there is no similar [issue](https://github.com/Stable-Baselines-Team/stable-baselines3-contrib/issues) in the repo
required: true required: true
- label: If I'm requesting a new feature, I have proposed alternatives
required: true

View File

@ -1,5 +1,5 @@
name: "❓ Question" name: "❓ Question"
description: How to ask a question regarding Stable-Baselines3 Contrib description: If you have a general question about Stable-Baselines3 Contrib
title: "[Question] question title" title: "[Question] question title"
labels: ["question"] labels: ["question"]
body: body:
@ -12,7 +12,9 @@ body:
id: question id: question
attributes: attributes:
label: ❓ Question label: ❓ Question
description: Your question. This can be e.g. questions regarding confusing or unclear behaviour of functions or a question if X can be done using stable-baselines3. Make sure to check out the documentation first. description: |
Your question. This can be e.g. questions regarding confusing or unclear behaviour of functions or a question if X can be done using stable-baselines3. Make sure to check out the documentation first.
**Important Note: If your question is anything like "Why is my code generating this error?", you must [submit a bug report](https://github.com/Stable-Baselines-Team/stable-baselines3-contrib/issues/new?assignees=&labels=bug&projects=&template=bug_report.yml&title=%5BBug%5D%3A+bug+title) instead.**
validations: validations:
required: true required: true
- type: checkboxes - type: checkboxes
@ -24,7 +26,7 @@ body:
required: true required: true
- label: I have read the [documentation](https://sb3-contrib.readthedocs.io/en/master/) - label: I have read the [documentation](https://sb3-contrib.readthedocs.io/en/master/)
required: true required: true
- label: If code there is, it is minimal and working - label: If code there is, it is [minimal and working](https://github.com/DLR-RM/stable-baselines3/issues/982#issuecomment-1197044014)
required: true required: true
- label: If code there is, it is formatted using the [markdown code blocks](https://help.github.com/en/articles/creating-and-highlighting-code-blocks) for both code and stack traces. - label: If code there is, it is formatted using the [markdown code blocks](https://help.github.com/en/articles/creating-and-highlighting-code-blocks) for both code and stack traces.
required: true required: true

View File

@ -19,7 +19,7 @@ jobs:
runs-on: ubuntu-latest runs-on: ubuntu-latest
strategy: strategy:
matrix: matrix:
python-version: ["3.7", "3.8", "3.9", "3.10"] python-version: ["3.8", "3.9", "3.10", "3.11"]
steps: steps:
- uses: actions/checkout@v3 - uses: actions/checkout@v3
@ -31,7 +31,7 @@ jobs:
run: | run: |
python -m pip install --upgrade pip python -m pip install --upgrade pip
# cpu version of pytorch # cpu version of pytorch
pip install torch==1.11+cpu -f https://download.pytorch.org/whl/torch_stable.html pip install torch==1.13+cpu -f https://download.pytorch.org/whl/torch_stable.html
# Install Atari Roms # Install Atari Roms
pip install autorom pip install autorom
@ -58,6 +58,8 @@ jobs:
- name: Type check - name: Type check
run: | run: |
make type make type
# skip PyType, doesn't support 3.11 yet
if: "!(matrix.python-version == '3.11')"
- name: Test with pytest - name: Test with pytest
run: | run: |
make pytest make pytest

View File

@ -4,18 +4,17 @@ channels:
- defaults - defaults
dependencies: dependencies:
- cpuonly=1.0=0 - cpuonly=1.0=0
- pip=21.1 - pip=22.3.1
- python=3.7 - python=3.8
- pytorch=1.11=py3.7_cpu_0 - pytorch=1.13.0=py3.8_cpu_0
- pip: - pip:
- gym==0.21
- cloudpickle - cloudpickle
- opencv-python-headless - opencv-python-headless
- pandas - pandas
- numpy - numpy
- matplotlib - matplotlib
- sphinx_autodoc_typehints - sphinx_autodoc_typehints
- stable-baselines3>=1.6.0 - stable-baselines3>=2.0.0
- sphinx>=4.2 - sphinx>=5.3,<7.0
- sphinx_rtd_theme>=1.0 - sphinx_rtd_theme>=1.0
- sphinx_copybutton - sphinx_copybutton

View File

@ -3,6 +3,32 @@
Changelog Changelog
========== ==========
Release 2.1.0a0 (WIP)
--------------------------
Breaking Changes:
^^^^^^^^^^^^^^^^^
- Removed Python 3.7 support
- SB3 now requires PyTorch > 1.13
New Features:
^^^^^^^^^^^^^
- Added Python 3.11 support
Bug Fixes:
^^^^^^^^^^
Deprecations:
^^^^^^^^^^^^^
Others:
^^^^^^^
Documentation:
^^^^^^^^^^^^^^
Release 2.0.0 (2023-06-22) Release 2.0.0 (2023-06-22)
-------------------------- --------------------------

View File

@ -1,8 +1,8 @@
[tool.ruff] [tool.ruff]
# Same as Black. # Same as Black.
line-length = 127 line-length = 127
# Assume Python 3.7 # Assume Python 3.8
target-version = "py37" target-version = "py38"
select = ["E", "F", "B", "UP", "C90", "RUF"] select = ["E", "F", "B", "UP", "C90", "RUF"]
# B028: Ignore explicit stacklevel` # B028: Ignore explicit stacklevel`
# RUF013: Too many false positives (implicit optional) # RUF013: Too many false positives (implicit optional)

View File

@ -1 +1 @@
2.0.0 2.1.0a0

View File

@ -77,7 +77,7 @@ setup(
long_description=long_description, long_description=long_description,
long_description_content_type="text/markdown", long_description_content_type="text/markdown",
version=__version__, version=__version__,
python_requires=">=3.7", python_requires=">=3.8",
# PyPI package information. # PyPI package information.
project_urls={ project_urls={
"Code": "https://github.com/Stable-Baselines-Team/stable-baselines3-contrib", "Code": "https://github.com/Stable-Baselines-Team/stable-baselines3-contrib",
@ -89,10 +89,10 @@ setup(
}, },
classifiers=[ classifiers=[
"Programming Language :: Python :: 3", "Programming Language :: Python :: 3",
"Programming Language :: Python :: 3.7",
"Programming Language :: Python :: 3.8", "Programming Language :: Python :: 3.8",
"Programming Language :: Python :: 3.9", "Programming Language :: Python :: 3.9",
"Programming Language :: Python :: 3.10", "Programming Language :: Python :: 3.10",
"Programming Language :: Python :: 3.11",
], ],
) )