Repository navigation
GH-44909: [Python][FlightRPC] Export auth channel types - #55807
Open
leo7martins wants to merge 1 commit into
Open
leo7martins wants to merge 1 commit into
leo7martins wants to merge 1 commit into
Conversation
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's wrong
pyarrow.flightdoes not export the auth channel typesClientAuthReader,ClientAuthSender,ServerAuthReaderandServerAuthSender, although they are implemented inpyarrow._flightand are passed to user code: customClientAuthHandler/ServerAuthHandlersubclasses receive these reader/sender objects as arguments, but users cannot reference their types without reaching into the privatepyarrow._flightmodule.Reproduced on Python 3.12 / PyArrow 20.0.0:
What changed
python/pyarrow/flight.py: re-export the four classes frompyarrow._flight.docs/source/python/api/flight.rst: add them to the Flight API reference, next to the handler interfaces that use them.python/pyarrow/tests/test_flight.py: regression test asserting each name is importable frompyarrow.flightand is the same object (is) as itspyarrow._flightcounterpart.Testing
pyarrow._flight, and that the patchedflight.py, loaded against that build, exports all four with object identity topyarrow._flight(the same assertions as the added test).Fixes #44909.
This was written with help from an AI coding assistant. Local verification above was performed by the assistant; full validation is left to CI.