Skip to content

Commit

Permalink
Add support for python 3.10 and 3.11 (#82)
Browse files Browse the repository at this point in the history
* Add support for Python 3.10 and 3.11

* Remove conda from unit test workflow

* Bump scipy to 1.13.0

* Fix scipy version for python 3.8

* Fix test dependency install

* Remove unit tests for python 3.12
  • Loading branch information
rbaltrusch authored Jun 22, 2024
1 parent ca8de36 commit f4a6a08
Show file tree
Hide file tree
Showing 4 changed files with 17 additions and 14 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/pylint.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ jobs:
runs-on: ubuntu-latest
strategy:
matrix:
python-version: ["3.8", "3.9"]
python-version: ["3.8", "3.9", "3.10", "3.11", "3.12"]
steps:
- uses: actions/checkout@v4
- name: Set up Python ${{ matrix.python-version }}
Expand Down
23 changes: 11 additions & 12 deletions .github/workflows/pytest-unit-tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,29 +3,28 @@ name: Unit tests
on: [push]

jobs:
build-linux:
build:
runs-on: ubuntu-latest
strategy:
max-parallel: 5
matrix:
python-version: ["3.8", "3.9"]
python-version: ["3.8", "3.9", "3.10", "3.11"]
steps:
- uses: actions/checkout@v4
- name: Set up Python 3.10
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v5
with:
python-version: ${{ matrix.python-version }}
- name: Add conda to system path
run: |
# $CONDA is an environment variable pointing to the root of the miniconda directory
echo $CONDA/bin >> $GITHUB_PATH
- name: Install dependencies
run: |
conda install pip
sudo apt install libopenblas-dev # scipy
python -m pip install --upgrade pip
pip install setuptools
pip install -e .
pip install -r tests/requirements.txt
- name: Install test dependencies
working-directory: tests
run: |
sudo apt install libopenblas-dev # scipy
pip install -r requirements.txt
- name: Test with pytest
working-directory: tests
run: |
pytest -m "not unreliable" .
pytest .
3 changes: 2 additions & 1 deletion requirements.txt
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
matplotlib==3.7.0
numpy==1.24.0
scipy==1.12.0
scipy==1.10.1; python_version < '3.9'
scipy==1.13.0; python_version >= '3.9'
3 changes: 3 additions & 0 deletions setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -39,6 +39,9 @@
"Programming Language :: Python :: 3.8",
"Programming Language :: Python :: 3.9",
"Programming Language :: Python :: 3.10",
"Programming Language :: Python :: 3.11",
# 3.12 doesn't work with setup.py, see: https://stackoverflow.com/questions/73533994/sub-package-not-importable-after-installation pylint: disable=line-too-long
# "Programming Language :: Python :: 3.12",
"Topic :: Artistic Software",
"Topic :: Desktop Environment",
"Topic :: Multimedia",
Expand Down

0 comments on commit f4a6a08

Please sign in to comment.