From 164252e3f9bec1465a5fb22e9868901fc2d95fe1 Mon Sep 17 00:00:00 2001 From: Nicco Kunzmann Date: Mon, 1 Jul 2024 22:34:37 +0100 Subject: [PATCH 1/9] use coveralls' github action --- .github/workflows/tests.yml | 24 +++++++++--------------- CHANGES.rst | 3 ++- 2 files changed, 11 insertions(+), 16 deletions(-) diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml index d96e5a87..1700ff9b 100644 --- a/.github/workflows/tests.yml +++ b/.github/workflows/tests.yml @@ -47,13 +47,11 @@ jobs: pip install tox coveralls coverage-python-version - name: Test run: tox -e ${{ matrix.config[1] }} - - name: Upload coverage data to coveralls.io - run: coveralls --service=github || which coveralls - env: - GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} - COVERALLS_REPO_TOKEN: ${{ secrets.CODECOV_TOKEN }} - COVERALLS_FLAG_NAME: ${{ matrix.config[1] }} - COVERALLS_PARALLEL: true + - name: Coveralls Parallel + uses: coverallsapp/github-action@v2 + with: + flag-name: run-${{ join(matrix.*, '-') }} + parallel: true coverage: # parallel test coverage upload @@ -64,15 +62,11 @@ jobs: # see https://docs.github.com/en/actions/using-workflows/workflow-syntax-for-github-actions#example-not-requiring-successful-dependent-jobs if: ${{ always() }} runs-on: ubuntu-latest - container: python:3-slim steps: - - name: Install dependencies - run: pip3 install --upgrade coveralls - - name: Upload coverage - run: coveralls --service=github --finish || which coveralls - env: - GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} - COVERALLS_REPO_TOKEN: ${{ secrets.CODECOV_TOKEN }} + - name: Coveralls Finished + uses: coverallsapp/github-action@v2 + with: + parallel-finished: true deploy-tag-to-pypi: # only deploy on tags, see https://stackoverflow.com/a/58478262/1320237 diff --git a/CHANGES.rst b/CHANGES.rst index 30aeb8f6..4e13b959 100644 --- a/CHANGES.rst +++ b/CHANGES.rst @@ -11,12 +11,13 @@ Minor changes: - Parallelize coverage - Rename ``master`` branch to ``main``, see `Issue `_ -- Update ``docs/usage.rst`` to use zoneinfo instead of pytz. +- Update ``docs/usage.rst`` to use zoneinfo instead of pytz. - Added missing public classes and functions to API documentation. - Improved namespace management in the ``icalendar`` directory. - Add Python version badge and badge for test coverage - Remove 4.x badge - Update list of ``tox`` environments +- Use Coveralls' GitHub Action Breaking changes: From dd78c64a8f97986a59b4411be49ea0d0e681d550 Mon Sep 17 00:00:00 2001 From: Nicco Kunzmann Date: Mon, 1 Jul 2024 22:46:38 +0100 Subject: [PATCH 2/9] disable docs CI because readthedocs tests it --- .github/workflows/tests.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml index 1700ff9b..f664c9e5 100644 --- a/.github/workflows/tests.yml +++ b/.github/workflows/tests.yml @@ -22,7 +22,7 @@ jobs: - ["3.9", "py39"] - ["3.10", "py310"] - ["pypy-3.9", "pypy3"] - - ["3.10", "docs"] +# - ["3.10", "docs"] Disable docs build because we have readthedocs - ["3.11", "py311"] - ["3.12", "py312"] From fe6f9c0b02c92a53152ef973d16baf82867515cf Mon Sep 17 00:00:00 2001 From: Nicco Kunzmann Date: Mon, 1 Jul 2024 22:52:48 +0100 Subject: [PATCH 3/9] coverage xml see https://github.com/collective/icalendar/actions/runs/9751493239/job/26913191286?pr=678#step:6:78 --- .github/workflows/tests.yml | 1 + tox.ini | 2 ++ 2 files changed, 3 insertions(+) diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml index f664c9e5..e392eadf 100644 --- a/.github/workflows/tests.yml +++ b/.github/workflows/tests.yml @@ -67,6 +67,7 @@ jobs: uses: coverallsapp/github-action@v2 with: parallel-finished: true + format: cobertura deploy-tag-to-pypi: # only deploy on tags, see https://stackoverflow.com/a/58478262/1320237 diff --git a/tox.ini b/tox.ini index 44cec7a2..304a064d 100644 --- a/tox.ini +++ b/tox.ini @@ -16,6 +16,7 @@ commands = coverage run --source=src/icalendar --omit=*/tests/hypothesis/* --omit=*/tests/fuzzed/* --module pytest [] coverage report coverage html + coverage xml [testenv:nopytz] # install with dependencies @@ -34,6 +35,7 @@ commands = coverage run --source=src/icalendar --omit=*/tests/hypothesis/* --omit=*/tests/fuzzed/* --module pytest [] coverage report coverage html + coverage xml [testenv:docs] deps = From 4a84bde8caf7c8bd40ce03a9631f6bc6a033669d Mon Sep 17 00:00:00 2001 From: Nicco Kunzmann Date: Mon, 1 Jul 2024 22:58:06 +0100 Subject: [PATCH 4/9] use only coverage.xml also enable tox docs again --- .github/workflows/tests.yml | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml index e392eadf..c2ed2d6a 100644 --- a/.github/workflows/tests.yml +++ b/.github/workflows/tests.yml @@ -22,7 +22,7 @@ jobs: - ["3.9", "py39"] - ["3.10", "py310"] - ["pypy-3.9", "pypy3"] -# - ["3.10", "docs"] Disable docs build because we have readthedocs + - ["3.10", "docs"] - ["3.11", "py311"] - ["3.12", "py312"] @@ -68,6 +68,9 @@ jobs: with: parallel-finished: true format: cobertura + file: coverage.xml + allow-empty: true + deploy-tag-to-pypi: # only deploy on tags, see https://stackoverflow.com/a/58478262/1320237 From f40d44b07783f8d6e490bb0589be40c8e3643820 Mon Sep 17 00:00:00 2001 From: Nicco Kunzmann Date: Mon, 1 Jul 2024 22:59:57 +0100 Subject: [PATCH 5/9] move arguments into first action --- .github/workflows/tests.yml | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml index c2ed2d6a..13c12a93 100644 --- a/.github/workflows/tests.yml +++ b/.github/workflows/tests.yml @@ -52,6 +52,8 @@ jobs: with: flag-name: run-${{ join(matrix.*, '-') }} parallel: true + file: coverage.xml + allow-empty: true coverage: # parallel test coverage upload @@ -68,9 +70,6 @@ jobs: with: parallel-finished: true format: cobertura - file: coverage.xml - allow-empty: true - deploy-tag-to-pypi: # only deploy on tags, see https://stackoverflow.com/a/58478262/1320237 From f86dc008f8083c925b568faf04e74cac2afec782 Mon Sep 17 00:00:00 2001 From: Nicco Kunzmann Date: Mon, 1 Jul 2024 23:14:45 +0100 Subject: [PATCH 6/9] remove docs build again --- .github/workflows/tests.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml index 13c12a93..1d24bd53 100644 --- a/.github/workflows/tests.yml +++ b/.github/workflows/tests.yml @@ -22,7 +22,7 @@ jobs: - ["3.9", "py39"] - ["3.10", "py310"] - ["pypy-3.9", "pypy3"] - - ["3.10", "docs"] +# - ["3.10", "docs"] # disable as readthedocs builds it - ["3.11", "py311"] - ["3.12", "py312"] From 2386e7e7abd741d90ff64480b735e71f8315701d Mon Sep 17 00:00:00 2001 From: Nicco Kunzmann Date: Mon, 1 Jul 2024 23:17:44 +0100 Subject: [PATCH 7/9] use correct coveralls flag --- .github/workflows/tests.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml index 1d24bd53..3d605c1e 100644 --- a/.github/workflows/tests.yml +++ b/.github/workflows/tests.yml @@ -50,7 +50,7 @@ jobs: - name: Coveralls Parallel uses: coverallsapp/github-action@v2 with: - flag-name: run-${{ join(matrix.*, '-') }} + flag-name: run-${{ matrix.config[1] }} parallel: true file: coverage.xml allow-empty: true From 80c203652666322f3656f4a76333daf0657a7a02 Mon Sep 17 00:00:00 2001 From: Steve Piercy Date: Mon, 1 Jul 2024 16:07:20 -0700 Subject: [PATCH 8/9] Cross-reference .github/workflows/tests.yml from .readthedocs.yml --- .readthedocs.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.readthedocs.yml b/.readthedocs.yml index 572db76f..42942bde 100644 --- a/.readthedocs.yml +++ b/.readthedocs.yml @@ -15,7 +15,7 @@ formats: all build: os: ubuntu-22.04 tools: - python: "3.11" + python: "3.11" # This Python version should be excluded from `.github/workflows/tests.yml`. python: install: From 812abb1bbadc954b4a198d93c13be3a766b23746 Mon Sep 17 00:00:00 2001 From: Nicco Kunzmann Date: Tue, 2 Jul 2024 00:47:14 +0100 Subject: [PATCH 9/9] Revert "Cross-reference .github/workflows/tests.yml from .readthedocs.yml" This reverts commit 80c203652666322f3656f4a76333daf0657a7a02. See https://github.com/collective/icalendar/pull/678/commits/80c203652666322f3656f4a76333daf0657a7a02#r1661640734 --- .readthedocs.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.readthedocs.yml b/.readthedocs.yml index 42942bde..572db76f 100644 --- a/.readthedocs.yml +++ b/.readthedocs.yml @@ -15,7 +15,7 @@ formats: all build: os: ubuntu-22.04 tools: - python: "3.11" # This Python version should be excluded from `.github/workflows/tests.yml`. + python: "3.11" python: install: