-
Notifications
You must be signed in to change notification settings - Fork 319
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
WIP Python 3.12 fixes #797
Conversation
Codecov ReportPatch coverage has no change and project coverage change:
Additional details and impacted files@@ Coverage Diff @@
## master #797 +/- ##
========================================
- Coverage 38% 12% -27%
========================================
Files 88 88
Lines 13084 10629 -2455
Branches 1830 1329 -501
========================================
- Hits 5074 1338 -3736
- Misses 7586 9158 +1572
+ Partials 424 133 -291
Flags with carried forward coverage won't be shown. Click here to find out more.
☔ View full report in Codecov by Sentry. |
Related to python/cpython@f0b234e Co-Authored-By: Victor Stinner <vstinner@python.org>
I've split this into 4 individual commits for easier review. |
) | ||
if ca_certs: | ||
context.load_verify_locations(ca_certs) | ||
if ciphers := kw.get('ciphers'): |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
sorry, this is 3.8+ construct, not going to happen anytime soon
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I know. My aim for this draft was to fix this for 3.12. Maintaining compatibility with previous Python versions was out of scope. If we can determine this approach is correct, we can add a giant if around the code. If the walrus would cause a problem even inside an if, no problem removing it.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
sorry, this is 3.8+ construct, not going to happen anytime soon
It can happen now! (#827)
Python 3.12 compatibility fix based on eventlet#797, absent use of :=
Hi, what needs to be done to get this merged? |
py3.7 compat (no |
Credit to @hroncok and Victor Stinner <vstinner@python.org> for logic (eventlet#797). This PR attempts to add compatibility for older Python versions. We draw the line at Python versions that predate ssl.SSLContext, though. The remaining Python 2.7 documentation doesn't even mention the version at which that was introduced.
Superseded by #817, which builds on this. Thank you for all your work! |
This makes the tests pass in Fedora. I have no ide what I am doing, so it may be entirely wrong.
This probably breaks with older Pythons.
Fixes #795