From 9a572959d1fd632165049c46fbf1315c2c3b0dba Mon Sep 17 00:00:00 2001 From: Sylvain MARIE Date: Mon, 9 Jun 2025 18:23:04 +0200 Subject: [PATCH 1/6] Fixed #82 --- setup.cfg | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/setup.cfg b/setup.cfg index c329944..5f6bd3a 100644 --- a/setup.cfg +++ b/setup.cfg @@ -44,7 +44,7 @@ install_requires = makefun>=1.5 tests_require = - pytest<8.4.0 + pytest numpy pandas tabulate From 1c4d78643e5962b0d62ab4a42f41c0a648342dd2 Mon Sep 17 00:00:00 2001 From: Sylvain MARIE Date: Mon, 9 Jun 2025 18:31:52 +0200 Subject: [PATCH 2/6] Now using python 3.11 for non-test nox sessions, and removed useless check about version.py containing type annotations. --- noxfile.py | 17 +++++++++-------- 1 file changed, 9 insertions(+), 8 deletions(-) diff --git a/noxfile.py b/noxfile.py index 43829db..8919eea 100644 --- a/noxfile.py +++ b/noxfile.py @@ -166,7 +166,7 @@ def tests(session, coverage, pkg_specs): session.run("genbadge", "coverage", "-i", f"{Folders.coverage_xml}", "-o", f"{Folders.coverage_badge}") -@nox.session(python=PY39) +@nox.session(python=PY311) def flake8(session): """Launch flake8 qualimetry.""" @@ -187,7 +187,7 @@ def flake8(session): rm_file(Folders.flake8_intermediate_file) -@nox.session(python=PY39) +@nox.session(python=PY311) def docs(session): """Generates the doc. Pass '-- serve' to serve it on a local http server instead.""" @@ -200,7 +200,7 @@ def docs(session): session.run("mkdocs", "build") -@nox.session(python=PY39) +@nox.session(python=PY311) def publish(session): """Deploy the docs+reports on github pages. Note: this rebuilds the docs""" @@ -245,18 +245,19 @@ def my_scheme(version_): session.run("python", "setup.py", "sdist", "bdist_wheel") - # Make sure that the generated _version.py file exists and is compliant with python 2.7 + # Make sure that the generated _version.py file exists version_py = Path(f"src/{pkg_name}/_version.py") if not version_py.exists(): raise ValueError("Error with setuptools_scm: _version.py file not generated") - if ":" in version_py.read_text(): - raise ValueError("Error with setuptools_scm: _version.py file contains annotations") + # ...and is compliant with python 2.7 + # if ":" in version_py.read_text(): + # raise ValueError("Error with setuptools_scm: _version.py file contains annotations") return current_tag, version -@nox.session(python=PY39) +@nox.session(python=PY311) def build(session): """Same as release but just builds""" @@ -265,7 +266,7 @@ def build(session): print(f"version: {version}") -@nox.session(python=PY39) +@nox.session(python=PY311) def release(session): """Create a release on github corresponding to the latest tag""" From 53d4147af67c08e4699cda612c944844c38a1e41 Mon Sep 17 00:00:00 2001 From: Sylvain MARIE Date: Mon, 9 Jun 2025 21:24:42 +0200 Subject: [PATCH 3/6] Updated long description --- docs/long_description.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/long_description.md b/docs/long_description.md index 82cf71c..43c49e5 100644 --- a/docs/long_description.md +++ b/docs/long_description.md @@ -1,6 +1,6 @@ # pytest-harvest -[![Python versions](https://img.shields.io/pypi/pyversions/pytest-harvest.svg)](https://pypi.python.org/pypi/pytest-harvest/) [![Build Status](https://github.com/smarie/python-pytest-harvest/actions/workflows/base.yml/badge.svg)](https://github.com/smarie/python-pytest-harvest/actions/workflows/base.yml) [![Tests Status](https://smarie.github.io/python-pytest-harvest/reports/junit/junit-badge.svg?dummy=8484744)](https://smarie.github.io/python-pytest-harvest/reports/junit/report.html) [![codecov](https://codecov.io/gh/smarie/python-pytest-harvest/branch/master/graph/badge.svg)](https://codecov.io/gh/smarie/python-pytest-harvest) +[![Python versions](https://img.shields.io/pypi/pyversions/pytest-harvest.svg)](https://pypi.python.org/pypi/pytest-harvest/) ![Pytest versions](https://img.shields.io/badge/pytest-6%20%7C%207%20%7C%208-blue) [![Build Status](https://github.com/smarie/python-pytest-harvest/actions/workflows/base.yml/badge.svg)](https://github.com/smarie/python-pytest-harvest/actions/workflows/base.yml) [![Tests Status](https://smarie.github.io/python-pytest-harvest/reports/junit/junit-badge.svg?dummy=8484744)](https://smarie.github.io/python-pytest-harvest/reports/junit/report.html) [![codecov](https://codecov.io/gh/smarie/python-pytest-harvest/branch/master/graph/badge.svg)](https://codecov.io/gh/smarie/python-pytest-harvest) [![Documentation](https://img.shields.io/badge/doc-latest-blue.svg)](https://smarie.github.io/python-pytest-harvest/) [![PyPI](https://img.shields.io/pypi/v/pytest-harvest.svg)](https://pypi.python.org/pypi/pytest-harvest/) [![Downloads](https://pepy.tech/badge/pytest-harvest)](https://pepy.tech/project/pytest-harvest) [![Downloads per week](https://pepy.tech/badge/pytest-harvest/week)](https://pepy.tech/project/pytest-harvest) [![GitHub stars](https://img.shields.io/github/stars/smarie/python-pytest-harvest.svg)](https://github.com/smarie/python-pytest-harvest/stargazers) From e086fa3b33c2e9d80cebef63351a0fab934a1f8e Mon Sep 17 00:00:00 2001 From: Sylvain MARIE Date: Mon, 9 Jun 2025 21:28:36 +0200 Subject: [PATCH 4/6] Fixed runner for GHA --- .github/workflows/base.yml | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/.github/workflows/base.yml b/.github/workflows/base.yml index 43aa50c..51759ce 100644 --- a/.github/workflows/base.yml +++ b/.github/workflows/base.yml @@ -25,10 +25,10 @@ jobs: - name: Checkout uses: actions/checkout@v4 - - name: Install python 3.9 + - name: Install python 3.11 uses: actions/setup-python@v5 with: - python-version: 3.9 + python-version: 3.11 architecture: x64 - name: Install noxfile requirements @@ -130,10 +130,10 @@ jobs: - name: Checkout uses: actions/checkout@v4 - - name: Install python 3.9 for nox + - name: Install python 3.11 for nox uses: actions/setup-python@v5 with: - python-version: 3.9 + python-version: 3.11 architecture: x64 - name: Install noxfile requirements @@ -158,10 +158,10 @@ jobs: fetch-depth: 0 # so that gh-deploy works # persist-credentials: false # see https://github.com/orgs/community/discussions/25702 - - name: Install python 3.9 for nox + - name: Install python 3.11 for nox uses: actions/setup-python@v5 with: - python-version: 3.9 + python-version: 3.11 architecture: x64 # 1) retrieve the reports generated previously From b63e5388b9746e25de96e33202c87d36eec29903 Mon Sep 17 00:00:00 2001 From: Sylvain MARIE Date: Mon, 9 Jun 2025 21:29:50 +0200 Subject: [PATCH 5/6] Added missing versions in cicd matrix --- noxfile.py | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) diff --git a/noxfile.py b/noxfile.py index 8919eea..9f13631 100644 --- a/noxfile.py +++ b/noxfile.py @@ -53,15 +53,24 @@ class Folders: ENVS = { # python 3.14 - numpy is not available in precompiled version for this python version yet # (PY314, "pytest-latest"): {"coverage": False, "pkg_specs": {"pip": ">19", "pytest": ""}}, + # (PY314, "pytest7.x"): {"coverage": False, "pkg_specs": {"pip": ">19", "pytest": "<8"}}, + # (PY314, "pytest6.x"): {"coverage": False, "pkg_specs": {"pip": ">19", "pytest": "<7"}}, # python 3.13 (PY313, "pytest-latest"): {"coverage": False, "pkg_specs": {"pip": ">19", "pytest": ""}}, + (PY313, "pytest7.x"): {"coverage": False, "pkg_specs": {"pip": ">19", "pytest": "<8"}}, + (PY313, "pytest6.x"): {"coverage": False, "pkg_specs": {"pip": ">19", "pytest": "<7"}}, # python 3.12 (PY312, "pytest-latest"): {"coverage": False, "pkg_specs": {"pip": ">19", "pytest": ""}}, (PY312, "pytest7.x"): {"coverage": False, "pkg_specs": {"pip": ">19", "pytest": "<8"}}, + (PY312, "pytest6.x"): {"coverage": False, "pkg_specs": {"pip": ">19", "pytest": "<7"}}, # python 3.11 - # We'll run this last for coverage + # We'll run 'pytest-latest' this last for coverage + (PY311, "pytest7.x"): {"coverage": False, "pkg_specs": {"pip": ">19", "pytest": "<8"}}, + (PY311, "pytest6.x"): {"coverage": False, "pkg_specs": {"pip": ">19", "pytest": "<7"}}, # python 3.10 (PY310, "pytest-latest"): {"coverage": False, "pkg_specs": {"pip": ">19", "pytest": ""}}, + (PY310, "pytest7.x"): {"coverage": False, "pkg_specs": {"pip": ">19", "pytest": "<8"}}, + (PY310, "pytest6.x"): {"coverage": False, "pkg_specs": {"pip": ">19", "pytest": "<7"}}, # python 3.9 (PY39, "pytest-latest"): {"coverage": False, "pkg_specs": {"pip": ">19", "pytest": ""}}, (PY39, "pytest7.x"): {"coverage": False, "pkg_specs": {"pip": ">19", "pytest": "<8"}}, From 298e6482b7e2dceff15d0cbc10bcada771a3a48e Mon Sep 17 00:00:00 2001 From: Sylvain MARIE Date: Mon, 9 Jun 2025 21:31:13 +0200 Subject: [PATCH 6/6] FIxed python version metadata declared --- setup.cfg | 7 ------- 1 file changed, 7 deletions(-) diff --git a/setup.cfg b/setup.cfg index 5f6bd3a..87f5603 100644 --- a/setup.cfg +++ b/setup.cfg @@ -20,13 +20,6 @@ classifiers = Topic :: Software Development :: Libraries :: Python Modules Topic :: Software Development :: Testing Programming Language :: Python - Programming Language :: Python :: 2 - Programming Language :: Python :: 2.7 - Programming Language :: Python :: 3 - Programming Language :: Python :: 3.5 - Programming Language :: Python :: 3.6 - 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