Uh oh!
There was an error while loading. Please reload this page.
Don't force full CI tests for non-test workflow and prek-only changes - #68802
Merged
potiuk merged 1 commit intoJun 25, 2026
Merged
Conversation
ENVIRONMENT_FILES forced the full test matrix on any .github/workflows change and on any scripts/ci/prek change. Those over-match: non-test workflows (security scans, doc publishing, notifications, backporting, stale/calendar bots) cannot affect test outcomes, and prek hooks drive static checks rather than the test matrix. Exclude non-test workflows from ENVIRONMENT_FILES (test/CI-config workflows like ci-amd, run-unit-tests, k8s-tests still force full), and move scripts/ci/prek to a new PREK_FILES group that triggers only the CI image build (so mypy-scripts and image-based static checks still run for a prek-only change) without forcing the full matrix. Static checks still run on every PR regardless; this only stops the unnecessary full test matrix for changes that cannot affect tests.
potiuk
requested review from
amoghrajesh, ashb, bugraoz93, choo121600, ephraimbuddy, gopidesupavan, jason810496, jedcunningham, jscheffl and vatsrahul1001
as code ownersJune 22, 2026 02:43
bugraoz93
approved these changes
Jun 25, 2026
Contributor
Backport successfully created: v3-3-testNote: As of Merging PRs targeted for Airflow 3.X In matter of doubt please ask in #release-management Slack channel.
|
potiuk added a commit
that referenced
this pull request
Jun 26, 2026
…only changes (#68802) (#68999) ENVIRONMENT_FILES forced the full test matrix on any .github/workflows change and on any scripts/ci/prek change. Those over-match: non-test workflows (security scans, doc publishing, notifications, backporting, stale/calendar bots) cannot affect test outcomes, and prek hooks drive static checks rather than the test matrix. Exclude non-test workflows from ENVIRONMENT_FILES (test/CI-config workflows like ci-amd, run-unit-tests, k8s-tests still force full), and move scripts/ci/prek to a new PREK_FILES group that triggers only the CI image build (so mypy-scripts and image-based static checks still run for a prek-only change) without forcing the full matrix. Static checks still run on every PR regardless; this only stops the unnecessary full test matrix for changes that cannot affect tests. (cherry picked from commit a4c269a) Co-authored-by: Jarek Potiuk <jarek@potiuk.com>
karenbraganz pushed a commit
to karenbraganz/airflow
that referenced
this pull request
Jun 30, 2026
…apache#68802) ENVIRONMENT_FILES forced the full test matrix on any .github/workflows change and on any scripts/ci/prek change. Those over-match: non-test workflows (security scans, doc publishing, notifications, backporting, stale/calendar bots) cannot affect test outcomes, and prek hooks drive static checks rather than the test matrix. Exclude non-test workflows from ENVIRONMENT_FILES (test/CI-config workflows like ci-amd, run-unit-tests, k8s-tests still force full), and move scripts/ci/prek to a new PREK_FILES group that triggers only the CI image build (so mypy-scripts and image-based static checks still run for a prek-only change) without forcing the full matrix. Static checks still run on every PR regardless; this only stops the unnecessary full test matrix for changes that cannot affect tests.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for freeto join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
ENVIRONMENT_FILESforces the full test matrix whenever any.github/workflows/*file or anyscripts/ci/prek/*file changes. Bothover-match work that cannot affect test outcomes:
codeql-analysis), doc publishing(
publish-docs-to-s3), notifications (ci-notification), backporting,stale/calendar bots, etc. — editing these can't change what tests do.
scripts/ci/prek/*) drive static checks, not the testmatrix.
Measuring ~2 weeks of
Tests (AMD)runs, these accidental triggers forced thefull matrix on ~57 runs (~1,417 compute-hours, ~12% of all FULL-build
compute, ~48% of the env-files FULL tier) — pure overhead.
This change:
ENVIRONMENT_FILESvia a negative-lookaheadallowlist. Test / CI-config workflows (
ci-amd,ci-arm,run-unit-tests,k8s-tests,helm-tests, image builds, …) still force thefull matrix — the exclusion is conservative (anything not explicitly listed
still forces full).
scripts/ci/prekinto a newPREK_FILESgroup that feeds onlyci_image_build, notfull_tests_needed. A prek-only change still buildsthe CI image so
mypy-scriptsand image-based static checks run — it just nolonger runs the whole test matrix.
Static checks run on every PR regardless, so this only removes the unnecessary
full test matrix for changes that cannot affect tests. Doc and tests
(
test_non_test_workflows_do_not_force_full_tests, updated prek case) included.Was generative AI tooling used to co-author this PR?
Generated-by: Claude Code (Opus 4.8) following the guidelines