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
Schedule Py_UNICODE API removal #82785
Comments
Python 3.3 deprecated the C API functions using Py_UNICODE type. Examples in the doc:
Currently, functions removal is scheduled for Python 4.0 but I would prefer that Python 4.0 doesn't have a long list of removed features, but no more than usual. So I'm trying to remove a few functions from Python 3.9, and try to prepare removal for others. Py_UNICODE C API was mostly kept for backward compatibility with Python 2. Since Python 2 support ends at the end of the year, can we start to organize Py_UNICODE C API removal? There are multiple questions:
I propose to:
Honestly, if the removal is causing too much issues, I'm fine to make slowdown the removal. It's just a matter of clearly communicating our intent. Maybe we should also announce the scheduled removal in What's in Python 3.9 and in the capi-sig mailing list. |
I searched "4.0" in the documentation:
|
A preleminary step was to modify PyUnicode_AsWideChar() and PyUnicode_AsWideCharString() to remove the internal caching: it has been done in Python 3.8.0 with bpo-30863. |
I want to remove them in 3.10 too. FWIW, ujson is apopular extension that uses these APIs. |
See bpo-36346. First we need to add compile-time deprecation warnings to all C API. Then add runtime deprecation warnings. And since this is a major compatibility breakage, it can take longer deprecation period. |
Oh, I failed to find this issue. Ok, I close mine as a duplicate. |
Note: these values reflect the state of the issue at the time it was migrated and might not reflect the current state.
Show more details
GitHub fields:
bugs.python.org fields:
The text was updated successfully, but these errors were encountered: