summaryrefslogtreecommitdiffstats
path: root/Lib/asyncio/runners.py
diff options
context:
space:
mode:
Diffstat (limited to 'Lib/asyncio/runners.py')
-rw-r--r--Lib/asyncio/runners.py3
1 files changed, 1 insertions, 2 deletions
diff --git a/Lib/asyncio/runners.py b/Lib/asyncio/runners.py
index bb54b72..5fbab03 100644
--- a/Lib/asyncio/runners.py
+++ b/Lib/asyncio/runners.py
@@ -51,8 +51,7 @@ def run(main, *, debug=False):
def _cancel_all_tasks(loop):
- to_cancel = [task for task in tasks.all_tasks(loop)
- if not task.done()]
+ to_cancel = tasks.all_tasks(loop)
if not to_cancel:
return