Guido van Rossum added the comment: Looks like a valid bug report, I like the test you provided, and the fix seems on the right track. Comments on the fix:
- I'd really like to see a rietveld diff for both patches. - Are there other places where a cancellation can have a similar effect? Maybe the same logic in put()? - The fix uses waiter.result() but if waiter itself is cancelled this will raise a CancelledError. This is probably fine because in that case no value has been put into it. But now this got me thinking -- how can the yield-from in get() receive a CancelledError without the waiter being cancelled? IOW how does the fix actually work??? (Maybe because the generator has already returned when the Task wrapping it is cancelled?) ---------- _______________________________________ Python tracker <rep...@bugs.python.org> <http://bugs.python.org/issue23812> _______________________________________ _______________________________________________ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com