This is an automated email from the ASF dual-hosted git repository.
vatsrahul1001 pushed a commit to branch v3-3-test
in repository https://gitbox.apache.org/repos/asf/airflow.git
The following commit(s) were added to refs/heads/v3-3-test by this push:
new 2141a7b746d [v3-3-test] Move known_airflow_exceptions.txt out of
scripts/ into generated/ (#69057) (#69060)
2141a7b746d is described below
commit 2141a7b746dbf2313a738291e9589ae29aaa021c
Author: github-actions[bot]
<41898282+github-actions[bot]@users.noreply.github.com>
AuthorDate: Mon Jun 29 08:42:02 2026 +0530
[v3-3-test] Move known_airflow_exceptions.txt out of scripts/ into
generated/ (#69057) (#69060)
The check-no-new-airflow-exceptions hook keeps its allowlist baseline in
scripts/ci/prek/known_airflow_exceptions.txt. That file is touched by any PR
that legitimately adds, removes, or moves a raise AirflowException --
typically
provider or core changes that have nothing to do with dev tooling. Because
it
lived under scripts/, boring-cyborg matched it against the scripts/**/*
glob and
auto-applied area:dev-tools and, worse, backport-to-v3-3-test, triggering
wrong
automated backports of unrelated provider PRs.
Move the generated allowlist to generated/known_airflow_exceptions.txt,
which no
boring-cyborg rule matches, so editing it no longer looks like a dev-tools
change.
The hook script reads/writes it from the repo-root generated/ directory;
.txt
files carry no license header, so nothing else changes.
(cherry picked from commit 78263d0c538ab489005b6ea1f104051a44fe60af)
Co-authored-by: Jarek Potiuk <[email protected]>
Co-authored-by: Rahul Vats <[email protected]>
---
{scripts/ci/prek => generated}/known_airflow_exceptions.txt | 0
scripts/ci/prek/check_new_airflow_exception_usage.py | 10 +++++-----
2 files changed, 5 insertions(+), 5 deletions(-)
diff --git a/scripts/ci/prek/known_airflow_exceptions.txt
b/generated/known_airflow_exceptions.txt
similarity index 100%
rename from scripts/ci/prek/known_airflow_exceptions.txt
rename to generated/known_airflow_exceptions.txt
diff --git a/scripts/ci/prek/check_new_airflow_exception_usage.py
b/scripts/ci/prek/check_new_airflow_exception_usage.py
index 88132824558..6ba97db865e 100755
--- a/scripts/ci/prek/check_new_airflow_exception_usage.py
+++ b/scripts/ci/prek/check_new_airflow_exception_usage.py
@@ -23,8 +23,8 @@
# ///
"""Check that no new ``raise AirflowException`` usages are introduced.
-All *existing* usages are recorded in ``known_airflow_exceptions.txt`` next to
-this script as ``relative/path::N`` entries (one per file), where ``N`` is the
+All *existing* usages are recorded in
``generated/known_airflow_exceptions.txt``
+as ``relative/path::N`` entries (one per file), where ``N`` is the
maximum number of ``raise AirflowException`` occurrences allowed in that file.
A file whose current count exceeds the recorded limit is treated as a violation
– use a dedicated exception class instead.
@@ -36,7 +36,7 @@ Default (files passed by prek/pre-commit):
When a file's count has *decreased*, the allowlist entry is tightened
automatically and the hook exits with a non-zero code so that pre-commit
reports the modified allowlist — just stage
- ``scripts/ci/prek/known_airflow_exceptions.txt`` and re-run.
+ ``generated/known_airflow_exceptions.txt`` and re-run.
``--all-files``:
Walk the whole repository and check every ``.py`` file.
@@ -201,7 +201,7 @@ def _check_airflow_exception_usage(
"If this usage is intentional and pre-existing, run:\n\n"
" [cyan]uv run
./scripts/ci/prek/check_new_airflow_exception_usage.py --generate[/cyan]\n\n"
"to regenerate the allowlist, then commit the updated\n"
- "[cyan]scripts/ci/prek/known_airflow_exceptions.txt[/cyan].",
+ "[cyan]generated/known_airflow_exceptions.txt[/cyan].",
title="[red]❌ Check failed[/red]",
border_style="red",
)
@@ -239,7 +239,7 @@ def main(argv: list[str] | None = None) -> int:
)
args = parser.parse_args(argv)
- manager = AllowlistManager(Path(__file__).parent /
"known_airflow_exceptions.txt")
+ manager = AllowlistManager(REPO_ROOT / "generated" /
"known_airflow_exceptions.txt")
if args.generate:
return manager.generate()