Repository navigation
Resolve provider namespaces from the real directory tree in prek hooks - #70468
Merged
potiuk merged 1 commit intoAug 13, 2026
Merged
Conversation
FrankYang0529
marked this pull request as ready for review
July 26, 2026 13:14
FrankYang0529
requested review from
amoghrajesh,
ashb,
bugraoz93,
gopidesupavan,
jason810496,
jscheffl and
potiuk
as code owners
July 26, 2026 13:14
Signed-off-by: PoAn Yang <[email protected]>
FrankYang0529
force-pushed
the
airflow-drop-known-second-level-paths
branch
from
August 6, 2026 01:33
fe2e600 to
f6ef16e
Compare
potiuk
approved these changes
Aug 13, 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
pushed a commit
that referenced
this pull request
Aug 17, 2026
…in prek hooks (#70468) (cherry picked from commit fd6b7db) Co-authored-by: PoAn Yang <[email protected]> Signed-off-by: PoAn Yang <[email protected]>
potiuk
pushed a commit
that referenced
this pull request
Aug 17, 2026
…in prek hooks (#70468) (#71553) (cherry picked from commit fd6b7db) Signed-off-by: PoAn Yang <[email protected]> Co-authored-by: PoAn Yang <[email protected]>
vatsrahul1001
pushed a commit
that referenced
this pull request
Sep 7, 2026
…in prek hooks (#70468) (#71553) (cherry picked from commit fd6b7db) Signed-off-by: PoAn Yang <[email protected]> Co-authored-by: PoAn Yang <[email protected]>
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.
Why
KNOWN_SECOND_LEVEL_PATHSis a hand-maintained list of namespace prefixes. A missing entry produces no signal at all.How
get_provider_id_from_path()walks up to the nearestprovider.yamland returns the provider id relative toproviders/:apache.hivefor a nested provider,amazonfor a top-level one.get_provider_namespace_from_path()usesget_provider_id_from_path()to detect the namespace. The segment before the dot is the namespace. The absence of a dot means the provider has none, so the answer comes from the provider's own position in the tree rather than from a list.check_providers_subpackages_all_have_init.py:folder.name in KNOWN_SECOND_LEVEL_PATHSbecomesfolder.name == namespace.mypy_folder.pyusesis_duplicated_namespace_init()to resolve each file's own provider and checks whether that file is that provider's namespace__init__.py.Verification
uv run --project scripts pytest scripts/tests/Was generative AI tooling used to co-author this PR?
{pr_number}.significant.rst, in airflow-core/newsfragments. You can add this file in a follow-up commit after the PR is created so you know the PR number.