Re-enable subprocess coverage in .coveragerc - #43
Conversation
pytest-cov 7.0.0 dropped automatic subprocess measurement; coverage.py must be told to patch subprocesses explicitly (patch = subprocess, requires coverage >= 7.10.6). Without this, the measure_freq / wave_analyzer script tests report 0% and total coverage drops. Co-authored-by: opencode <opencode@anomalyco.ai>
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: Organization UI Review profile: CHILL Plan: Pro Plus Run ID: 📒 Files selected for processing (1)
Included review availability: Your plan provides up to 2 included reviews per hour; 1 remains after this review. 📝 WalkthroughWalkthroughThe coverage configuration adds a ChangesCoverage configuration
Estimated code review effort: 1 (Trivial) | ~2 minutes Merge Risk: 🔵 Low · up to This change re-enables subprocess coverage, but it depends on CI using coverage.py 7.10.6 or newer; verify or pin that dependency before merging to avoid continued missing coverage. 🚥 Pre-merge checks | ✅ 5✅ Passed checks (5 passed)
✨ Finishing Touches🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
Welcome to Codecov 🎉Once you merge this PR into your default branch, you're all set! Codecov will compare coverage reports and display results in all future pull requests. Thanks for integrating Codecov - We've got you covered ☂️ |
Problem
Coverage dropped from ~80% to ~61% on the master CI run without any code change.
scripts/measure_freq.py and scripts/wave_analyzer.py are tested via subprocess. That subprocess coverage was measured automatically by pytest-cov's .pth mechanism. pytest-cov 7.0.0 (Sept 2025) removed automatic subprocess measurement; it now requires coverage.py's native subprocess patching. The last successful Codecov report predates this (Dec 2024, pytest-cov 6.x); the first successful run since installed pytest-cov 7.x and script coverage collapsed to 0%.
Fix
Add [run] patch = subprocess to .coveragerc to re-enable subprocess measurement (requires coverage >= 7.10.6).
Verification
Run on this branch, scripts coverage should return to non-zero in the Codecov report.
Summary by CodeRabbit