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 eric.snow
Recipients asvetlov, eric.snow, vstinner, yselivanov
Date 2019-05-29.20:32:13
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1559161933.7.0.172141919083.issue37088@roundup.psfhosted.org>
In-reply-to
Content
Note that I'm working on making pending calls per-interpreter (see issue #33608 and https://github.com/python/cpython/pull/12360 (since reverted)).

As to exposing Py_AddPendingCall() as sys.addpendingcall, that might be opening a can of worms.  Injecting code into the eval loop at some arbitrary ("soon") future time requires care and the code isn't well exercised historically (much like subinterpreters).  By making it easier to use the pending calls API (e.g. from Python code) we may be introducing an attractive nuisance.  It also adds burden on other Python implementations.

My point is, let's think this through before adding sys.addpendingcall(). :)  Is there another way this could be done that doesn't open a can of worms?

Also, at the very least it should probably be a "private" function (i.e sys._addpendingcall).
History
Date User Action Args
2019-05-29 20:32:13eric.snowsetrecipients: + eric.snow, vstinner, asvetlov, yselivanov
2019-05-29 20:32:13eric.snowsetmessageid: <1559161933.7.0.172141919083.issue37088@roundup.psfhosted.org>
2019-05-29 20:32:13eric.snowlinkissue37088 messages
2019-05-29 20:32:13eric.snowcreate