THRIFT-6265: Drop the backports.ssl_match_hostname dependency - #3863
Merged
Merged
Conversation
Client: py setup.py added backports.ssl_match_hostname to the "ssl" extra when run on a Python older than 3.5. The build requires setuptools 69 or later, which needs Python 3.8, and the library supports Python 3.10 onwards. The branch is therefore never taken, and the extra has been empty in every build. The "ssl" extra itself stays, so that installing thrift[ssl] keeps working. The AppVeyor build no longer installs the package either. Co-Authored-By: Claude Opus 5 (1M context) <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.
JIRA: THRIFT-6265
Client: py
lib/py/setup.pyaddedbackports.ssl_match_hostname>=3.5to thesslextra whensys.hexversion < 0x03050000. No build can take that branch:pyproject.tomlbuilds withsetuptools>=69, which itself needs Python 3.8 or later.LANGUAGES.md, CI matrix).Changes:
lib/py/setup.py: the branch is removed. Thesslextra stays defined, and stays empty as it has been in every build, sopip install thrift[ssl]keeps working without a "does not provide the extra" warning.build/appveyor/MSVC-appveyor-full.bat: the AppVeyor build no longer installsbackports.ssl_match_hostname.The dead
backportsfallback inlib/py/src/transport/sslcompat.py, and the message inTSSLSocket.pythat names the package, are part of the code THRIFT-6233 changes. This PR leaves both to that ticket.Verification
No test can tell the two versions apart: the removed branch is unreachable on every interpreter that can run the build. Instead I checked:
egg_infometadata (Provides-Extra,Requires-Dist,requires.txt) is identical before and after, on Python 3.10.12 with the distribution's setuptools and on Python 3.12.14 with setuptools 69+.pip install ".[ssl]"succeeds on 3.12 without an extras warning.flake8 lib/py/setup.pyis clean.🤖 Generated with Claude Code