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 ajoino, alex.gronholm, asvetlov, chris.jerdonek, gvanrossum, iritkatriel, jab, njs, tinchester, yselivanov
Date 2022-02-17.19:27:39
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1645126059.7.0.0140710117323.issue46771@roundup.psfhosted.org>
In-reply-to
Content
Lots of food for thought! There seem to be mostly two discussions: API design for the new asyncio cancel scopes (do we make it more like Trio or more like async-timeout?); and cancel semantics in edge cases.

I'll pass on the API design for now: I recommend that Tin and Andrew agree on some middle ground first. (Personally I could do without move_on(), I'd just add a try/except TimeoutError.)

On the cancel edge case, I am beginning to warm up to (ab)using the existing cancel message hack, rather than a separate nonce. I think the message argument could be the cancel scope or its id().

I think Andrew missed one case: in his second diagram, what if the explicit cancel() happened *after* the timeout (but still in the same iteration)? That's the case that makes me want to delete those two lines from Task.cancel() (see my earlier message).

(Sorry, I've gotta go play now.)
History
Date User Action Args
2022-02-17 19:27:39gvanrossumsetrecipients: + gvanrossum, njs, jab, asvetlov, alex.gronholm, chris.jerdonek, yselivanov, tinchester, iritkatriel, ajoino
2022-02-17 19:27:39gvanrossumsetmessageid: <1645126059.7.0.0140710117323.issue46771@roundup.psfhosted.org>
2022-02-17 19:27:39gvanrossumlinkissue46771 messages
2022-02-17 19:27:39gvanrossumcreate