From 3a2d0b6a3e6cc400089896e60a2f3c093a8e7e65 Mon Sep 17 00:00:00 2001 From: Sebastian Pipping Date: Mon, 11 Dec 2023 15:25:34 +0100 Subject: [PATCH] Fix tox and readthedocs (#221) * tox.ini: Fix broken path for --cov= argument Broken since the move in commit d076fa2112c8dea1e27d545d6a92b83c58498325 . * tox.yml: Stop using non-existent environment "coverage" for tox >=4.9.0 Related: - https://github.com/tox-dev/tox/pull/3089 - https://github.com/tox-dev/tox/commit/21244587ae7ec478645edc46cbf16098dd9f2e70 * readthedocs.yml: Remove discontinued key "python.system_packages" Error was: > Problem in your project's configuration. Invalid configuration option > "python.system_packages". This configuration key has been deprecated > and removed. Refer to https://blog.readthedocs.com/use-system-packages-deprecated/ > to read more about this change and how to upgrade your config file. Build log at https://readthedocs.org/projects/ansi2html/builds/21826996/ . Upstream docs at https://blog.readthedocs.com/drop-support-system-packages/ . Fix may be incomplete and may need a closer look. --- .github/workflows/tox.yml | 2 +- readthedocs.yml | 1 - tox.ini | 2 +- 3 files changed, 2 insertions(+), 3 deletions(-) diff --git a/.github/workflows/tox.yml b/.github/workflows/tox.yml index a9595ec..5dbebfc 100644 --- a/.github/workflows/tox.yml +++ b/.github/workflows/tox.yml @@ -95,7 +95,7 @@ jobs: - name: Combine coverage data if: ${{ startsWith(matrix.passed_name, 'py') }} # produce a single .coverage file at repo root - run: tox -e coverage + run: tox -e py - name: Upload coverage data if: ${{ startsWith(matrix.passed_name, 'py') }} diff --git a/readthedocs.yml b/readthedocs.yml index a74e871..f2d1439 100644 --- a/readthedocs.yml +++ b/readthedocs.yml @@ -5,7 +5,6 @@ mkdocs: python: version: 3.8 - system_packages: false install: - method: pip path: . diff --git a/tox.ini b/tox.ini index e6f9658..c430095 100644 --- a/tox.ini +++ b/tox.ini @@ -17,7 +17,7 @@ deps = pytest-cov sitepackages = False usedevelop = True -commands = python -m pytest -ra --cov=ansi2html --no-cov-on-fail --cov-append --cov-report=xml:{toxworkdir}/coverage-{envname}.xml +commands = python -m pytest -ra --cov=src/ --no-cov-on-fail --cov-append --cov-report=xml:{toxworkdir}/coverage-{envname}.xml [testenv:lint] description = Runs all linting tasks