]> git.ipfire.org Git - thirdparty/Python/cpython.git/commit
[3.8] bpo-32751: Wait for task cancel in asyncio.wait_for() when timeout <= 0 (GH...
authorElvis Pranskevichus <elvis@magic.io>
Wed, 26 Aug 2020 20:59:17 +0000 (13:59 -0700)
committerGitHub <noreply@github.com>
Wed, 26 Aug 2020 20:59:17 +0000 (13:59 -0700)
commit57b698886b47bb81c782c2ba80a8a72fe66c7aad
tree2e4138f42e267b3dcbba13e16effb31c2d4eb3b3
parent6e1954cd8286e083e7f8d09516d91b6b15769a4e
[3.8] bpo-32751: Wait for task cancel in asyncio.wait_for() when timeout <= 0 (GH-21895) (#21967)

When I was fixing bpo-32751 back in GH-7216 I missed the case when
*timeout* is zero or negative.  This takes care of that.

Props to @aaliddell for noticing the inconsistency..
(cherry picked from commit c517fc712105c8e5930cb42baaebdbe37fc3e15f)
Lib/asyncio/tasks.py
Lib/test/test_asyncio/test_tasks.py
Misc/NEWS.d/next/Library/2020-08-15-15-50-12.bpo-32751.85je5X.rst [new file with mode: 0644]