[v3-2-test] Don't force the full test matrix for large example_dags-only changes (#68042)#68052
Closed
github-actions[bot] wants to merge 1 commit into
Closed
[v3-2-test] Don't force the full test matrix for large example_dags-only changes (#68042)#68052github-actions[bot] wants to merge 1 commit into
github-actions[bot] wants to merge 1 commit into
Conversation
…nly changes (#68042) A large diff to example DAGs (e.g. a single provider example like #68037, +667/-119) tripped the `_is_large_enough_pr` line-count gate, which set `full-tests-needed=true` and fanned out the entire matrix — core DB tests, Kubernetes, Helm, PROD images, all-provider compat and special tests — for what is illustrative, non-shipped code. Exclude `example_dags/` from `PYTHON_PRODUCTION_FILES` (the "production code" definition that feeds the line-count gate) for both the airflow-core top-level `airflow/example_dags/` and the nested `providers/<name>/.../example_dags/` layout. Example DAGs are still selected for their own tests via the broader `ALL_AIRFLOW_PYTHON_FILES` / `ALL_PROVIDERS_PYTHON_FILES` groups, so they keep running the relevant core/provider tests — they just no longer force the full matrix. (cherry picked from commit 4adf4e6) Co-authored-by: Shahar Epstein <60007259+shahar1@users.noreply.github.com>
1 task
1 task
shahar1
added a commit
to shahar1/airflow
that referenced
this pull request
Jun 5, 2026
On push to release branches like v3-2-test, the full test matrix was unconditionally running because _should_run_all_tests_and_versions() didn't distinguish between push events to main vs release branches. Release branch pushes should only run selective tests (based on changed files), while canaries (SCHEDULE) and manual triggers (WORKFLOW_DISPATCH) still get the full matrix. Added branch-aware gating: push to release branches now returns False from _should_run_all_tests_and_versions() unless other conditions (pyproject.toml changes, etc.) require full tests. Includes test case validating the behavior across different event types and branches. Fixes: apache#68052 Co-Authored-By: Claude Haiku 4.5 <noreply@anthropic.com>
shahar1
added a commit
that referenced
this pull request
Jun 5, 2026
… (v3-X-test) (#68056) On push to release branches like v3-2-test, the full test matrix was unconditionally running because _should_run_all_tests_and_versions() didn't distinguish between push events to main vs release branches. Release branch pushes should only run selective tests (based on changed files), while canaries (SCHEDULE) and manual triggers (WORKFLOW_DISPATCH) still get the full matrix. Added branch-aware gating: push to release branches now returns False from _should_run_all_tests_and_versions() unless other conditions (pyproject.toml changes, etc.) require full tests. Includes test case validating the behavior across different event types and branches. Fixes: #68052 Co-authored-by: Claude Haiku 4.5 <noreply@anthropic.com>
bugraoz93
pushed a commit
that referenced
this pull request
Jun 5, 2026
…#68057) On push to release branches like v3-2-test, the full test matrix was unconditionally running because _should_run_all_tests_and_versions() didn't distinguish between push events to main vs release branches. Release branch pushes should only run selective tests (based on changed files), while canaries (SCHEDULE) and manual triggers (WORKFLOW_DISPATCH) still get the full matrix. Added branch-aware gating: push to release branches now returns False from _should_run_all_tests_and_versions() unless other conditions (pyproject.toml changes, etc.) require full tests. Includes test case validating the behavior across different event types and branches. Fixes: #68052 Co-authored-by: Claude Haiku 4.5 <noreply@anthropic.com>
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 free
to 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.
A large diff to example DAGs (e.g. a single provider example like
#68037, +667/-119) tripped the
_is_large_enough_prline-count gate, which set
full-tests-needed=trueand fanned out theentire matrix — core DB tests, Kubernetes, Helm, PROD images, all-provider
compat and special tests — for what is illustrative, non-shipped code.
Exclude
example_dags/fromPYTHON_PRODUCTION_FILES(the "productioncode" definition that feeds the line-count gate) for both the airflow-core
top-level
airflow/example_dags/and the nestedproviders/<name>/.../example_dags/layout. Example DAGs are still selectedfor their own tests via the broader
ALL_AIRFLOW_PYTHON_FILES/ALL_PROVIDERS_PYTHON_FILESgroups, so they keep running the relevantcore/provider tests — they just no longer force the full matrix.
(cherry picked from commit 4adf4e6)
Co-authored-by: Shahar Epstein 60007259+shahar1@users.noreply.github.com