Skip to content

Commit

Permalink
chore: modernize supported Python versions
Browse files Browse the repository at this point in the history
- Add support for Python 3.12 and 3.13.

- Drop support for Python 3.7 and 3.8.

tests: parallel tox invocation

ci: update action versions
  • Loading branch information
tseaver committed Feb 22, 2025
1 parent 0490581 commit e6942b5
Show file tree
Hide file tree
Showing 4 changed files with 31 additions and 35 deletions.
36 changes: 7 additions & 29 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,11 +14,11 @@ jobs:
strategy:
matrix:
python:
- "3.7"
- "3.8"
- "3.9"
- "3.10"
- "3.11"
- "3.12"
- "3.13"
steps:

- name: Checkout
Expand All @@ -38,12 +38,6 @@ jobs:
run: |
tox -e py${{ matrix.python }}
- name: Upload coverage results
uses: actions/upload-artifact@v2
with:
name: coverage-artifacts
path: .coverage.py${{ matrix.python }}

run-unittests-w-deps:
name: unit-w-deps
runs-on: ubuntu-latest
Expand All @@ -55,7 +49,7 @@ jobs:
- name: Setup Python
uses: actions/setup-python@v2
with:
python-version: 3.8
python-version: 3.9

- name: Install tox
run: |
Expand All @@ -67,17 +61,14 @@ jobs:
tox -e w_deps
- name: Upload coverage results
uses: actions/upload-artifact@v2
uses: actions/upload-artifact@v4
with:
name: coverage-artifacts
path: .coverage.w_deps

report-coverage:
name: cover
runs-on: ubuntu-latest
needs:
- run-unittests
- run-unittests-w-deps

steps:

Expand All @@ -87,20 +78,7 @@ jobs:
- name: Setup Python
uses: actions/setup-python@v2
with:
python-version: "3.10"
python-version: "3.12"

- name: Install coverage
run: |
python -m pip install --upgrade setuptools pip wheel
python -m pip install coverage
- name: Download coverage results
uses: actions/download-artifact@v2
with:
name: coverage-artifacts
path: .coverage-results/

- name: Report coverage results
run: |
coverage combine .coverage-results/.coverage*
coverage report --show-missing --fail-under=100
- run: pip install tox
- run: tox -e py312-cover,w_deps,cover
7 changes: 7 additions & 0 deletions CHANGES.rst
Original file line number Diff line number Diff line change
@@ -1,6 +1,13 @@
``repoze.retry`` Changelog
==========================

2.1 (unreleased)
----------------

- Add support for Python 3.12 and 3.13

- Drop support for Python 3.7 and 3.8.

2.0 (2023-01-23)
----------------

Expand Down
8 changes: 6 additions & 2 deletions setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -21,17 +21,21 @@ def _read_file(filename):
"Intended Audience :: Developers",
"Programming Language :: Python",
"Programming Language :: Python :: 3",
"Programming Language :: Python :: 3.7",
"Programming Language :: Python :: 3.8",
"Programming Language :: Python :: 3.9",
"Programming Language :: Python :: 3.10",
"Programming Language :: Python :: 3.11",
"Programming Language :: Python :: 3.12",
"Programming Language :: Python :: 3.13",
"Programming Language :: Python :: Implementation :: CPython",
"Programming Language :: Python :: Implementation :: PyPy",
"Topic :: Internet :: WWW/HTTP",
"Topic :: Internet :: WWW/HTTP :: WSGI",
"Topic :: Internet :: WWW/HTTP :: WSGI :: Middleware",
],
python_requires=">=3.9",
install_requires=[
'setuptools',
],
keywords='wsgi middleware retry',
author="Agendaless Consulting",
author_email="[email protected]",
Expand Down
15 changes: 11 additions & 4 deletions tox.ini
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[tox]
envlist =
py37,py38,py39,py310,py311,pypy3,w_deps,cover,docs
py39,py310,py311,py312,py313,pypy3,w_deps,cover,docs

[testenv]
usedevelop=true
Expand All @@ -14,18 +14,23 @@ setenv =

[testenv:w_deps]
basepython =
python3.8
python3.9
deps =
transaction
ZODB
Zope>=4.0
pytest
pytest-cov

[testenv:py312-cover]
commands =
python --version
pytest --cov {posargs:}

[testenv:cover]
skip_install = true
basepython =
python3.10
python3.12
commands =
coverage combine
coverage report --fail-under=100 --show-missing
Expand All @@ -34,10 +39,12 @@ deps =
coverage
setenv =
COVERAGE_FILE=.coverage
#depends = py39,py310,py311,py312,py313,pypy3,w_deps
depends = py312-cover,w_deps

[testenv:docs]
basepython =
python3.10
python3.12
commands =
sphinx-build -b html -d docs/_build/doctrees docs docs/_build/html
deps =
Expand Down

0 comments on commit e6942b5

Please sign in to comment.