News for hackers. Stuff that matters.
Re:I'm not feeling the async pressure by Too on Thursday January 02, 2020 @03:05AM (#21933702)
Python has something similar, you can cancel() any async task and it will throw a CancelledError inside the ongoing operation.

I'm not sure how it would solve backpressure though, because canceling a task is normally done by the caller, while backpressure comes from the other direction of the call stack.

Re:I'm not feeling the async pressure by the_mitsuhiko on Thursday January 02, 2020 @03:41AM (#21933834)
Cancel in Python and a cancellation token are very different concepts. Cancellations in Python are not passed through the same way and you can’t await a cancellation.