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 yselivanov
Recipients Mark.Shannon, lukasz.langa, scoder, serhiy.storchaka, v2m, yselivanov
Date 2020-09-21.18:36:07
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1600713368.26.0.646855902289.issue41756@roundup.psfhosted.org>
In-reply-to
Content
> If you disagree with me, please say why, don't just merge the PR.

Apologies, Mark. I didn't intend to merge something bypassing your opinion; just missed your comment between reviewing multiple PRs in a few unrelated repos. I'm sorry.

On the actual naming subject, you proposed:

> `PySendResult PyIter_Send(PyObject *obj, PyObject *arg, PyObject **result);`

The problem with using this name is that ideally we should also support non-native coroutine and generator implementations (i.e. resolve the "send" attribute and call it using Python calling convention). Ideally we should have two C APIs: one low-level supporting only native objects and a high level one, supporting all kinds of them.

Can we perhaps add both `PyGen_Send()` and `PyCoro_Send()` for now that would only accept generators and coroutines respectively? After that we can discuss adding a more generic `PyIter_Send`?


> Would you revert the PR, please.

Since this is in 3.10/master that nobody uses right now except us (Python core devs), can we just issue a follow up PR to fix whatever is there to fix? I'd like to avoid the churn of reverting, and again, I apologize for pushing this a bit hastily.  Let me know if you actually want a revert and I'll do that.
History
Date User Action Args
2020-09-21 18:36:08yselivanovsetrecipients: + yselivanov, scoder, lukasz.langa, Mark.Shannon, serhiy.storchaka, v2m
2020-09-21 18:36:08yselivanovsetmessageid: <1600713368.26.0.646855902289.issue41756@roundup.psfhosted.org>
2020-09-21 18:36:08yselivanovlinkissue41756 messages
2020-09-21 18:36:07yselivanovcreate