This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

Author vstinner
Recipients p-ganssle, vstinner
Date 2019-07-05.08:52:18
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1562316738.15.0.452177212137.issue37499@roundup.psfhosted.org>
In-reply-to
Content
By the way, PyObject_CallFunction("O") has a surprising behavior: if you pass a tuple, the tuple is unpacked, whereas any other type is passed directly. See bpo-28977.

I would prefer to fix the API since it caused severe bugs in the past, like asyncio generator bug bpo-21209.

But I'm not sure if we can do it without a deprecation period... I'm not sure that we should deprecate anything, since I would expect that PyObject_CallFunction(func, "O", tuple) calls func(tuple) rather than func(*tuple)...
History
Date User Action Args
2019-07-05 08:52:18vstinnersetrecipients: + vstinner, p-ganssle
2019-07-05 08:52:18vstinnersetmessageid: <1562316738.15.0.452177212137.issue37499@roundup.psfhosted.org>
2019-07-05 08:52:18vstinnerlinkissue37499 messages
2019-07-05 08:52:18vstinnercreate