python/steering-council

Is it OK to remove _PyObject_Vectorcall?

Closed this issue · 8 comments

PEP-590 says:

The underscore in the names _PyObject_Vectorcall and _Py_TPFLAGS_HAVE_VECTORCALL indicates that this API may change in minor Python versions. When finalized (which is planned for Python 3.9), they will be renamed to PyObject_Vectorcall and Py_TPFLAGS_HAVE_VECTORCALL. The old underscore-prefixed names will remain available as aliases.

I'm not aware of a decision to override the PEP. But the reasoning behind the changes is scattered in a maze of issues, PRs and topics that were never collected into a PEP, so it's very possible that I'm missing something. (It seems @vstinner is in charge of the removals, but I don't know where to ask or discuss -- see e.g. here).

The question I want to ask is practically intractable at this point, so I'll ask a simple one instead:
Does the SC think that it is OK to remove _PyObject_Vectorcall without a change to PEP-590, new PEP, or SC decision?

When I removed these private functions, I wasn't aware that PEP 590 had a specific section about them.

Last June, I only found 8 projects using it: python/cpython#106084 (comment)

In the meanwhile, I added some vectorcall APIs for Python 3.8 in the pythoncapi-compat project: https://pythoncapi-compat.readthedocs.io/en/latest/api.html#c.PyObject_Vectorcall

I captured my personal thoughts on this theme in python/cpython#111481 (comment)

The SC has been chatting about the overall theme behind recent presumed-private C API removals and we're happy to see that the C API working group appears to be looking into the question per Guido on 106320.

Of course that would require there to be a C API WG, which is awaiting approval of PEP 731 (#210).

Right. There are strong personal opinions floating around, spanning the full range of "revert it all"–"moratorium"–"full steam ahead".

Of course that would require there to be a C API WG, which is awaiting approval of PEP 731 (#210).

Correct, hence why it's actively being discussed by the SC.

Update: PEP 590 aliases kept for backward compatibility were restored in Python 3.13 by python/cpython#112115

Yhg1s commented

Now that the C API WG PEP is accepted and this has been solved for 3.13 anyway, the SC is leaving this question for the WG.