Skip to content

Commit 8b8fe0a

Browse files
authored
Update workflows to support Python 3.11 and 3.12 (#52)
This updates workflow files to support Python 3.11 and 3.12. Also bumps the setup.py version to 1.1
1 parent 6b58b98 commit 8b8fe0a

File tree

3 files changed

+37
-34
lines changed

3 files changed

+37
-34
lines changed

.github/workflows/pylint.yml

+13-13
Original file line numberDiff line numberDiff line change
@@ -7,17 +7,17 @@ jobs:
77
runs-on: ubuntu-latest
88
strategy:
99
matrix:
10-
python-version: ["3.8", "3.9", "3.10"]
10+
python-version: ["3.8", "3.9", "3.10", "3.11", "3.12"]
1111
steps:
12-
- uses: actions/checkout@v4
13-
- name: Set up Python ${{ matrix.python-version }}
14-
uses: actions/setup-python@v5
15-
with:
16-
python-version: ${{ matrix.python-version }}
17-
- name: Install dependencies
18-
run: |
19-
python -m pip install --upgrade pip
20-
pip install pylint
21-
- name: Analysing the code with pylint
22-
run: |
23-
pylint bach_generator -d=import-error --fail-under=9
12+
- uses: actions/checkout@v4
13+
- name: Set up Python ${{ matrix.python-version }}
14+
uses: actions/setup-python@v5
15+
with:
16+
python-version: ${{ matrix.python-version }}
17+
- name: Install dependencies
18+
run: |
19+
python -m pip install --upgrade pip
20+
pip install pylint
21+
- name: Analysing the code with pylint
22+
run: |
23+
pylint bach_generator -d=import-error --fail-under=9

.github/workflows/pytest-unit-tests.yml

+20-20
Original file line numberDiff line numberDiff line change
@@ -8,24 +8,24 @@ jobs:
88
strategy:
99
max-parallel: 5
1010
matrix:
11-
python-version: ["3.8", "3.9", "3.10"]
11+
python-version: ["3.8", "3.9", "3.10", "3.11", "3.12"]
1212
steps:
13-
- uses: actions/checkout@v4
14-
- name: Set up Python 3.10
15-
uses: actions/setup-python@v5
16-
with:
17-
python-version: ${{ matrix.python-version }}
18-
- name: Add conda to system path
19-
run: |
20-
# $CONDA is an environment variable pointing to the root of the miniconda directory
21-
echo $CONDA/bin >> $GITHUB_PATH
22-
- name: Install dependencies
23-
run: |
24-
conda install pip
25-
pip install -e .
26-
- name: Test with pytest
27-
working-directory: tests
28-
run: |
29-
sudo apt install libopenblas-dev # scipy
30-
pip install -r requirements.txt
31-
pytest .
13+
- uses: actions/checkout@v4
14+
- name: Set up Python
15+
uses: actions/setup-python@v5
16+
with:
17+
python-version: ${{ matrix.python-version }}
18+
- name: Add conda to system path
19+
run: |
20+
# $CONDA is an environment variable pointing to the root of the miniconda directory
21+
echo $CONDA/bin >> $GITHUB_PATH
22+
- name: Install dependencies
23+
run: |
24+
conda install pip
25+
pip install -e .
26+
- name: Test with pytest
27+
working-directory: tests
28+
run: |
29+
sudo apt install libopenblas-dev # scipy
30+
pip install -r requirements.txt
31+
pytest .

setup.py

+4-1
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88

99
setuptools.setup(
1010
name="bach_generator",
11-
version="1.0.2",
11+
version="1.1.0",
1212
description="Machine learning based Bach music generator",
1313
long_description=project_dir.joinpath("README.md").read_text(encoding="utf-8"),
1414
long_description_content_type="text/markdown",
@@ -39,6 +39,9 @@
3939
"Programming Language :: Python :: 3.8",
4040
"Programming Language :: Python :: 3.9",
4141
"Programming Language :: Python :: 3.10",
42+
"Programming Language :: Python :: 3.11",
43+
# 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
44+
# "Programming Language :: Python :: 3.12",
4245
"Topic :: Artistic Software",
4346
"Topic :: Desktop Environment",
4447
"Topic :: Multimedia",

0 commit comments

Comments
 (0)