Repository navigation
Add ci-coverage label to force LLVM coverage jobs on tests-only PRs - #117866
Conversation
The coverage family (the coverage build, the amd_llvm_coverage test shards, the excluded_from_llvm jobs, and the LLVM Coverage merge job) is auto-skipped on PRs with no build-affecting changes, because the coverage of the compiled binary would be identical to master. The new ci-coverage label overrides this automatic skip, so a tests-only PR can still run the coverage pipeline on the tests it adds. The explicit ci-no-coverage label still wins if both labels are present. Co-Authored-By: Claude Fable 5 <[email protected]>
|
Workflow [PR], commit [bd4a75b] Summary: ✅ AI ReviewSummaryThis PR adds a Findings
Tests
Final VerdictChanges look correct after the follow-up fix, but the PR is still missing the focused regression coverage needed to prove the new |
| ): | ||
| # The `ci-coverage` label overrides only this automatic skip: it lets | ||
| # a tests-only PR still measure the coverage of the tests it adds. | ||
| if Labels.CI_COVERAGE in _info_cache.pr_labels: |
There was a problem hiding this comment.
Because this PR itself changes filter_job.py, it already trips _has_coverage_pipeline_changes, so the coverage family would run even if the new ci-coverage branch were dead. That leaves the main contract of the PR unproven: a pure tests-only diff on an unchanged binary.
Please add a focused regression test around the Config Workflow filtering path for at least these cases: no label, ci-coverage, and ci-coverage together with ci-no-coverage to prove the precedence rule.
The excluded_from_llvm jobs run on a plain (non-instrumented) build and produce no coverage data. On a tests-only PR their tests already run in the regular test jobs, so forcing them together with the coverage jobs would only burn CI time. Co-Authored-By: Claude Fable 5 <[email protected]>
The ci-coverage label only bypassed should_skip_job. The later 'Filter not affected jobs' pass in native_jobs.py still dropped the coverage family when no changed file matched the coverage jobs' digest_config (e.g. a docs-only PR), so the label did not force the jobs across the full 'no build-affecting changes' surface. Add a generic mechanism to praktika: a workflow filter hook can return (False, Workflow.FILTER_HOOK_FORCE_JOB) to force-include a job. Such jobs are treated as affected in _filter_unaffected_jobs, and their dependencies (the coverage build) are kept alive through the usual rescue propagation. The ci-coverage branch of should_skip_job now returns this sentinel. Co-Authored-By: Claude Fable 5 <[email protected]>
The LLVM coverage family (the coverage build, the
amd_llvm_coveragetest shards, theexcluded_from_llvmjobs, and theLLVM Coveragemerge job) is skipped automatically on PRs with no build-affecting changes. The reason: the coverage of the compiled binary would be identical to master. But sometimes the author of a tests-only PR wants to run the coverage pipeline anyway, for example to see the coverage of the tests the PR adds.This PR adds a new
ci-coveragelabel. It overrides only the automatic skip, symmetric to the existingci-no-coveragelabel. The explicitci-no-coveragelabel still wins if both labels are present. Theexcluded_from_llvmjobs stay skipped even with the label: they run on a plain (non-instrumented) build and produce no coverage data, and their tests already run in the regular test jobs of the PR. A note about the label's effect is added to the CI report, in the same way as for the otherci-*labels.Bypassing
should_skip_jobalone is not enough: the later "Filter not affected jobs" pass would still drop the coverage jobs when no changed file matches theirdigest_config(e.g. a docs-only PR). So this PR also adds a generic praktika mechanism: a workflow filter hook can return(False, Workflow.FILTER_HOOK_FORCE_JOB)to force-include a job. Forced jobs are treated as affected in_filter_unaffected_jobs, and their dependencies are kept alive through the usual rescue propagation. The job cache is still respected: a digest-identical coverage build is reused, not rebuilt.Validation note: this PR cannot exercise the new branch in its own CI. Its diff touches
filter_job.py, which is in_COVERAGE_PIPELINE_PATHS, so the coverage family runs here regardless of the label. The contract was validated by an offline replay of the Config Workflow decision pipeline against the real PR job graph (realshould_skip_job, real digest configs, real_filter_unaffected_jobs) with a pure tests-only diff (tests/queries/0_stateless/09999_new_test.sql): without the label all 25 coverage-family jobs are filtered; with the label 23 coverage jobs run and the 2excluded_from_llvmjobs stay skipped. After the merge, the end-to-end behavior should be confirmed once with a real tests-only PR carrying the label.The
ci-coveragelabel does not exist in the repository label list yet. It must be created once:gh label create ci-coverage --description "Force LLVM coverage jobs to run on a PR with no build-affecting changes (e.g. tests-only)" --color 8256D0.Changelog category (leave one):
Changelog entry (a user-readable short description of the changes that goes into CHANGELOG.md):
...
🤖 Generated with Claude Code
Version info
26.9.1.633(included in26.9and later)