Skip to content

Commit 9cfc3b3

Browse files
fix(ci): override pyproject addopts so auditor tests don't need pytest-cov
The citation-audit workflow only installs ``pytest`` (no coverage toolchain) because the auditor tests are stdlib-only. But pytest auto-applies the project's ``pyproject.toml`` addopts, which include ``--cov=statspai`` — so the CI run died with ``ERROR: usage: ... unrecognized arguments --cov=statspai`` and never reached the live auditor steps. Override addopts with ``-o 'addopts='`` to run the tests in isolation. Local ``pytest`` (with the full [dev] extras) keeps its coverage reporting unchanged. Verification: ran the exact CI invocation locally, python -m pytest tests/test_audit_citations.py \ tests/test_audit_bib_duplicates.py -o 'addopts=' -q -> 49 passed in 0.99s Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
1 parent 742ec43 commit 9cfc3b3

1 file changed

Lines changed: 9 additions & 1 deletion

File tree

.github/workflows/citation-audit.yml

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -72,7 +72,15 @@ jobs:
7272
# Fast (<1s) stdlib-only tests guarding DOI regex / Q-network
7373
# stopword / parse_bib brace-balance regressions. Runs BEFORE
7474
# the live auditors so a broken auditor can't silently pass.
75-
run: python -m pytest tests/test_audit_citations.py tests/test_audit_bib_duplicates.py --no-cov -q
75+
#
76+
# -o 'addopts=' overrides the project-wide pyproject.toml addopts
77+
# (which pull in --cov=statspai for local dev); the auditor tests
78+
# are stdlib-only and don't need the full coverage toolchain.
79+
run: |
80+
python -m pytest \
81+
tests/test_audit_citations.py \
82+
tests/test_audit_bib_duplicates.py \
83+
-o 'addopts=' -q
7684
7785
- name: Run paper.bib duplicate auditor (strict)
7886
id: bib_audit

0 commit comments

Comments
 (0)