Message246137
| Author | yselivanov |
|---|---|
| Recipients | Ben.Darnell, Yury.Selivanov, asvetlov, gvanrossum, martin.panter, ncoghlan, python-dev, r.david.murray, scoder, vstinner, yselivanov |
| Date | 2015-07-03.05:28:05 |
| SpamBayes Score | -1.0 |
| Marked as misclassified | Yes |
| Message-id | <1435901285.73.0.645336828546.issue24400@psf.upfronthosting.co.za> |
| In-reply-to |
| Content | |
|---|---|
Guido, Ben, Stefan, Nick, I want to re-open this issue. I'm still not satisfied with the current state of things, mainly with the __instancecheck__ hack for Awaitable & Coroutine ABCs (as Ben initially suggested). I think we should remove the __instancecheck__ from the ABCs, and resurrect inspect.isawaitable() function: 1. abc.Coroutine and abc.Awaitable will guarantee that objects that implement them have '__await__' and it's safe to access it (that means that they will fail for generator-based coroutines). 2. inspect.isgenerator() can be used along with inspect.isawaitable() to detect generator-based coroutines (generators with CO_ITERABLE_COROUTINE flag). |
|
| History | |||
|---|---|---|---|
| Date | User | Action | Args |
| 2015-07-03 05:28:05 | yselivanov | set | recipients: + yselivanov, gvanrossum, ncoghlan, scoder, vstinner, r.david.murray, asvetlov, Yury.Selivanov, python-dev, Ben.Darnell, martin.panter |
| 2015-07-03 05:28:05 | yselivanov | set | messageid: <1435901285.73.0.645336828546.issue24400@psf.upfronthosting.co.za> |
| 2015-07-03 05:28:05 | yselivanov | link | issue24400 messages |
| 2015-07-03 05:28:05 | yselivanov | create | |