Skip to content

Commit

Permalink
Fix rare concurrency issue with tox writing coverage report
Browse files Browse the repository at this point in the history
  • Loading branch information
skeletorXVI committed Dec 9, 2024
1 parent cd529c1 commit 68eb6b3
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 1 deletion.
3 changes: 2 additions & 1 deletion .github/workflows/run-checks.yml
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,8 @@ jobs:
source .venv/bin/activate
coverage erase
tox run-parallel -f py${{ matrix.python-version }} --parallel-no-spinner --parallel-live
coverage xml
coverage combine --data-file=.coverage
coverage xml --data-file=.coverage
- name: Upload coverage reports to Codecov
uses: codecov/codecov-action@v4
Expand Down
3 changes: 3 additions & 0 deletions pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -74,6 +74,9 @@ warn_return_any = true
warn_unused_configs = true
files = ["src", "tests"]

[tool.coverage.run]
data_file = ".coverage.${TOX_ENV_NAME}"

[tool.coverage.report]
exclude_lines = [
"if TYPE_CHECKING:"
Expand Down

0 comments on commit 68eb6b3

Please sign in to comment.