Repository navigation
Migrate airflow-core to httpx2 - #74244
Draft
zach-overflow wants to merge 10 commits into
Draft
zach-overflow wants to merge 10 commits into
zach-overflow wants to merge 10 commits into
Conversation
httpx has stalled: fixes that landed in httpx2 (a fork of httpx 0.28.1) have not shipped upstream, and starlette has already migrated, so FastAPI following is a matter of time. Moving the Execution API client now keeps the SDK on a maintained HTTP stack. Objects do not cross the httpx/httpx2 boundary, so the in-process Execution API transports move with the client that consumes them; the rest of airflow-core stays on httpx and migrates separately. related: apache#70522
Compat tests pair the repo's devel-common helpers with a released Airflow whose Task SDK is still on httpx. Pinning the helper to httpx2 hands those clients a transport from the wrong package, and httpx rejects the response stream it gets back.
Every other third-party hook in the repo pins an immutable SHA; a mutable tag lets the hook change under CI without a diff.
Both HTTP stacks can coexist while compatibility jobs use older SDK distributions. The migration needs regression coverage for its logging behavior without exposing development-only helpers as public APIs.
Tests added on main for in-process shutdown still referenced httpx, which this branch no longer imports in the module.
This branch has not been deployed
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.
What?
airflow-core's usage ofhttpxtohttpx2, following the general migration guidance here.httpx2#73116) since there is some code overlap.ast-greppre-commit check to prevent re-introducinghttpxin the Task SDK, mirroring the providers one.Why?
httpxusage forhttpx2#70522httpx2#73116Was generative AI tooling used to co-author this PR?
Code changes Generated-by: [Claude Code, Opus extra-high effort] following the guidelines
Self-reviewed and adjusted as needed by hand
PR description hand-written
Additional Notes
providersis already merged. See Migrate google + pagerduty + anthropic providers tohttpx2#72111main.