[Python-Dev] Issue #23903 - stable API is incomplete (original) (raw)
Steve Dower steve.dower at python.org
Tue Dec 20 20:52:15 EST 2016
- Previous message (by thread): [Python-Dev] [python-committers] Should I delay 3.5.3 and 3.4.6 by two weeks?
- Next message (by thread): [Python-Dev] Issue #23903 - stable API is incomplete
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
For those who aren't aware, the stable API (PEP 384) is broken on Windows because the exports from python3.dll have not been kept up to date.
Over at http://bugs.python.org/issue23903 we're trying to address this by automatically generating the DLL based on the headers. This has shown that many more functions and data items are in the stable ABI than expected.
If it's left entirely to me, I'm planning to add all the public APIs into python3.dll, which will commit them to the stable API for good, and remove the _private APIs that have been added since we last updated the DLL.
However, if you've added an API recently that you didn't mean to be in the stable API, here is your chance to remove it. The full list of APIs that have never been available on Windows in the stable ABI but are in the headers are below. If it should not be considered long-term stable, then it needs "#ifndef Py_LIMITED_API" around it.
Note that anything NOT on this list has already been released, and so it cannot be removed from the stable API at this time. I want to resolve this for 3.5.3 (that is, release all of these as stable and then it cannot be undone), which is coming up very soon, so if any of the public APIs should NOT be stable, please fix them, and if any of the private APIs SHOULD be stable, they'll probably need version-specific guards (see moduleobject.h).
Cheers, Steve
Full list of APIs to be added to python3.dll:
PyAST_FromNode PyAST_FromNodeObject PyAST_Validate PyCmpWrapper_Type PyCodec_NameReplaceErrors PyErr_GetExcInfo PyErr_ResourceWarning PyErr_SetExcFromWindowsErr PyErr_SetExcFromWindowsErrWithFilename PyErr_SetExcFromWindowsErrWithFilenameObject PyErr_SetExcFromWindowsErrWithFilenameObjects PyErr_SetExcInfo PyErr_SetExcWithArgsKwargs PyErr_SetFromErrnoWithFilenameObjects PyErr_SetFromWindowsErr PyErr_SetFromWindowsErrWithFilename PyErr_SetImportError PyErr_SetImportErrorSubclass PyErr_SyntaxLocationEx PyExc_BlockingIOError PyExc_BrokenPipeError PyExc_ChildProcessError PyExc_ConnectionAbortedError PyExc_ConnectionError PyExc_ConnectionRefusedError PyExc_ConnectionResetError PyExc_FileExistsError PyExc_FileNotFoundError PyExc_InterruptedError PyExc_IsADirectoryError PyExc_ModuleNotFoundError PyExc_NotADirectoryError PyExc_PermissionError PyExc_ProcessLookupError PyExc_RecursionError PyExc_ResourceWarning PyExc_StopAsyncIteration PyExc_TimeoutError PyExc_WindowsError PyImport_AddModuleObject PyImport_ExecCodeModuleObject PyImport_ImportFrozenModuleObject PyImport_ImportModuleLevelObject PyMarshal_ReadObjectFromString PyMarshal_WriteLongToFile PyMarshal_WriteObjectToFile PyMarshal_WriteObjectToString PyMem_Calloc PyMember_GetOne PyMember_SetOne PyMemoryView_FromMemory PyModuleDef_Init PyModuleDef_Type PyModule_AddFunctions PyModule_ExecDef PyModule_FromDefAndSpec2 PyModule_GetNameObject PyModule_NewObject PyModule_SetDocString PyNode_AddChild PyNode_Free PyNode_ListTree PyNode_New PyNumber_InPlaceMatrixMultiply PyNumber_MatrixMultiply PyOS_CheckStack PyOS_FSPath PyObject_Calloc PyObject_GenericSetDict PyParser_SimpleParseStringFlagsFilename PySys_AddXOption PySys_GetXOptions PyThread_GetInfo PyThread_ReInitTLS PyThread_acquire_lock PyThread_acquire_lock_timed PyThread_allocate_lock PyThread_create_key PyThread_delete_key PyThread_delete_key_value PyThread_exit_thread PyThread_free_lock PyThread_get_key_value PyThread_get_stacksize PyThread_get_thread_ident PyThread_init_thread PyThread_release_lock PyThread_set_key_value PyThread_set_stacksize PyThread_start_new_thread PyUnicode_AsMBCSString PyUnicode_AsUCS4 PyUnicode_AsUCS4Copy PyUnicode_AsWideCharString PyUnicode_DecodeCodePageStateful PyUnicode_DecodeLocale PyUnicode_DecodeLocaleAndSize PyUnicode_DecodeMBCS PyUnicode_DecodeMBCSStateful PyUnicode_EncodeCodePage PyUnicode_EncodeLocale PyUnicode_FindChar PyUnicode_GetLength PyUnicode_ReadChar PyUnicode_Substring PyUnicode_WriteChar Py_DecodeLocale Py_EncodeLocale Py_FileSystemDefaultEncodeErrors Py_SetPath Py_hexdigits _PyBytes_DecodeEscape _PyDebug_PrintTotalRefs _PyThreadState_Current _PyTrash_thread_deposit_object _PyTrash_thread_destroy_chain _PyUnicode_DecodeUnicodeEscape _Py_AddToAllObjects _Py_ForgetReference _Py_GetRefTotal _Py_HashSecret_Initialized _Py_NegativeRefcount _Py_NewReference _Py_PrintReferenceAddresses _Py_PrintReferences _Py_RefTotal
- Previous message (by thread): [Python-Dev] [python-committers] Should I delay 3.5.3 and 3.4.6 by two weeks?
- Next message (by thread): [Python-Dev] Issue #23903 - stable API is incomplete
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]