ci: separate PR coverage from test matrix#2180
Conversation
Greptile SummaryThis PR separates coverage reporting from the PR test matrix by introducing a reusable
|
| Filename | Overview |
|---|---|
| .github/workflows/_coverage.yml | New reusable workflow that abstracts the Python 3.11 + coverage configuration, used by both develop and PR coverage workflows. |
| .github/workflows/pr-coverage.yml | New PR-scoped coverage workflow that fires on code changes, delegates to _coverage.yml, and emits a pr-coverage-summary gate check. |
| .github/workflows/pr-tests.yml | Removes coverage-specific matrix include and CODECOV_TOKEN secret; Python 3.11 remains in the matrix, running tests twice per PR alongside pr-coverage.yml (pre-existing noted issue). |
| .github/workflows/pr-tests-skip.yml | Adds a pr-coverage-summary skip job so doc-only PRs satisfy the new required status check without running coverage. |
| .github/workflows/develop-coverage.yml | Refactored to call the new _coverage.yml reusable workflow instead of duplicating hardcoded parameters; clean simplification. |
Reviews (2): Last reviewed commit: "ci: centralize coverage workflow configu..." | Re-trigger Greptile
📝 WalkthroughWalkthroughCoverage execution is moved into a reusable workflow, PR coverage is added with completion reporting, develop coverage is rerouted, and standard PR tests no longer pass coverage settings. Skipped PRs now report skipped coverage. ChangesCoverage CI workflow
Estimated code review effort: 2 (Simple) | ~10 minutes Sequence Diagram(s)sequenceDiagram
participant PullRequest as pull_request event
participant PRCoverage as PR Coverage
participant CoverageWorkflow as _coverage.yml
participant TestWorkflow as _test.yml
participant CoverageSummary as coverage summary
PullRequest->>PRCoverage: trigger on eligible changes
PRCoverage->>CoverageWorkflow: invoke with CODECOV_TOKEN
CoverageWorkflow->>TestWorkflow: run with coverage enabled
PRCoverage->>CoverageSummary: report completion after coverage
🚥 Pre-merge checks | ✅ 6✅ Passed checks (6 passed)
✨ Finishing Touches📝 Generate docstrings
🧪 Generate unit tests (beta)
Comment |
|
The duplicate execution is intentional. The regular matrix verifies uninstrumented compatibility across every supported Python version, while the separate workflow isolates coverage timing and reporting. Removing Python 3.11 from the matrix would make that matrix incomplete and couple supported-version maintenance to the coverage configuration. We prefer the extra runner cost over those semantics. |
|
That's a clear and reasonable trade-off — keeping the matrix complete across all supported versions is worth the extra runner cost, and coupling version maintenance to coverage config would be a real maintenance hazard down the line. Makes sense. Shall I remember this as a rule: "In this repository, running Python 3.11 in both the PR test matrix and the coverage workflow is intentional — do not flag it as duplicate execution"? |
Description
Separates Python 3.11 coverage from the PR test matrix so test timing and coverage reporting are tracked independently.
Related Issue(s)
Verification
AI Assistance
Checklist
Summary by CodeRabbit
New Features
Improvements