We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent cc1ffe1 commit 7400200Copy full SHA for 7400200
packages/common-library/src/common_library/async_tools.py
@@ -90,7 +90,10 @@ async def cancel_wait_task(
90
CancelledError: raised ONLY if owner is being cancelled.
91
"""
92
93
- task.cancel()
+ cancelling = task.cancel()
94
+ if not cancelling:
95
+ return # task was alredy cancelled
96
+
97
assert task.cancelling() # nosec
98
assert not task.cancelled() # nosec
99
0 commit comments