Skip to content

Commit

Permalink
feat: add Python 3.11 support
Browse files Browse the repository at this point in the history
  • Loading branch information
Agrendalath committed Apr 17, 2024
1 parent 78e4135 commit 89bd1eb
Show file tree
Hide file tree
Showing 3 changed files with 15 additions and 5 deletions.
15 changes: 12 additions & 3 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -19,19 +19,28 @@ jobs:
fail-fast: false
matrix:
os: [ubuntu-20.04]
python-version: [3.8, 3.12]
toxenv: [django42, quality, translations-django42]
toxenv: [py38-django42, py311-django42, py312-django42, py38-quality, py311-quality, py312-quality, translations]

steps:
- name: checkout repo
uses: actions/checkout@v3
with:
submodules: recursive

- name: Extract the Python version from tox environment
run: |
if [[ "${{ matrix.toxenv }}" =~ py[0-9]+ ]]; then
PYTHON_VERSION=$(echo "${{ matrix.toxenv }}" | sed -E 's/py([0-9])([0-9]+).*/\1.\2/')
else
# Default version
PYTHON_VERSION=3.8
fi
echo "PYTHON_VERSION=$PYTHON_VERSION" >> $GITHUB_ENV
- name: setup python
uses: actions/setup-python@v4
with:
python-version: ${{ matrix.python-version }}
python-version: ${{ env.PYTHON_VERSION }}

- name: Install translations dependencies
if: ${{ startsWith(matrix.toxenv, 'translations') }}
Expand Down
1 change: 1 addition & 0 deletions setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -118,6 +118,7 @@ def package_data(pkg, root_list):
classifiers=[
'Programming Language :: Python',
'Programming Language :: Python :: 3.8',
'Programming Language :: Python :: 3.11',
'Programming Language :: Python :: 3.12',
'Framework :: Django',
'Framework :: Django :: 4.2',
Expand Down
4 changes: 2 additions & 2 deletions tox.ini
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
[tox]
envlist = py{38, 312}-django{42},quality,translations-django{42}
envlist = py{38,311,312}-django{42},py{38,311,312}-quality,translations

[pycodestyle]
exclude = .git,.tox
Expand Down Expand Up @@ -34,7 +34,7 @@ commands =
pylint drag_and_drop_v2
pylint tests --rcfile=tests/pylintrc

[testenv:translations-django42]
[testenv:translations]
allowlist_externals =
make
deps =
Expand Down

0 comments on commit 89bd1eb

Please sign in to comment.