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 gvanrossum
Recipients djarb, gvanrossum, martin.panter, vstinner, yselivanov
Date 2014-08-25.18:04:32
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1408989872.92.0.732014103915.issue22239@psf.upfronthosting.co.za>
In-reply-to
Content
While I understand your problem, I really do not want to enable recursive event loops. While they are popular in some event systems (IIRC libevent relies heavily on the concept), I have heard some strong objections from other parts, and I am trying to keep the basic event loop functionality limited to encourage interoperability with other even loop systems (e.g. Tornado, Twisted).

In my own experience, the very programming technique that you are proposing has caused some very hard to debug problems that appeared as very infrequent and hard to predict stack overflows.

I understand this will make your code slightly less elegant in some cases, but I think in the end it is for the best if you are required to define an explicit method (declared to be a coroutine) for membership testing of a remote object.  The explicit "yield from" will help the readers of your code understand that global state may change (due to other callbacks running while you are blocked), and potentially help a static analyzer find bugs in your code before they take down your production systems.
History
Date User Action Args
2014-08-25 18:04:33gvanrossumsetrecipients: + gvanrossum, vstinner, djarb, martin.panter, yselivanov
2014-08-25 18:04:32gvanrossumsetmessageid: <1408989872.92.0.732014103915.issue22239@psf.upfronthosting.co.za>
2014-08-25 18:04:32gvanrossumlinkissue22239 messages
2014-08-25 18:04:32gvanrossumcreate