[Python-Dev] Adding c-api async protocol support
Yury Selivanov
yselivanov.ml at gmail.com
Thu Jun 25 17:43:54 CEST 2015
Hi Arc,
On 2015-06-24 10:36 PM, Arc Riley wrote:
> A type slot for tp_as_async has already been added (which is good!) but we
> do not currently seem to have protocol functions for awaitable types.
>
> I would expect to find an Awaitable Protocol listed under Abstract Objects
> Layer, with functions like PyAwait_Check, PyAwaitIter_Check, and
> PyAwaitIter_Next, etc.
>
> Specifically its currently difficult to test whether an object is awaitable
> or an awaitable iterable, or use said objects from the c-api without
> relying on method testing/calling mechanisms.
The request is reasonable, I created a couple of bug tracker
issues:
http://bugs.python.org/issue24511
http://bugs.python.org/issue24510
Let's continue the discussion there.
Yury
More information about the Python-Dev
mailing list