Many functions and methods implemented in C still parse their arguments with PyArg_ParseTuple() or PyArg_UnpackTuple().
They have no signature for introspection and use the slow METH_VARARGS calling convention.
There are 131 such PyMethodDef entries outside the test modules: _curses 25, _ctypes 16, _interpchannels 13 (GH-139141), time 11, _io 9, _tkinter 8, _thread 6, _csv 5, socket 3, sys 3, and 32 more in 27 files.
A few of them cannot be converted: the behaviour of socket.sendto(), socket.setsockopt() and socket.ioctl() depends on the number or the value of the arguments, and Argument Clinic rejects module-level __getattr__() as a special method.
I am going to submit a separate PR per module.
Linked PRs
Many functions and methods implemented in C still parse their arguments with
PyArg_ParseTuple()orPyArg_UnpackTuple().They have no signature for introspection and use the slow
METH_VARARGScalling convention.There are 131 such
PyMethodDefentries outside the test modules:_curses25,_ctypes16,_interpchannels13 (GH-139141),time11,_io9,_tkinter8,_thread6,_csv5,socket3,sys3, and 32 more in 27 files.A few of them cannot be converted: the behaviour of
socket.sendto(),socket.setsockopt()andsocket.ioctl()depends on the number or the value of the arguments, and Argument Clinic rejects module-level__getattr__()as a special method.I am going to submit a separate PR per module.
Linked PRs