From 3162bc4cace4e22ab39f7e1722cb09dcf4321688 Mon Sep 17 00:00:00 2001 From: George Li Date: Tue, 18 Nov 2025 16:17:20 +0000 Subject: [PATCH] asynq: use py3 generator throws the asyncio stuff is py3 so also do this Reviewers: hwanseung Test Plan: unit tests still work Addresses Pull Requests: Differential Revision: Asana Tasks: Screenshot: CC: Deploy To: --- asynq/decorators.py | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/asynq/decorators.py b/asynq/decorators.py index 5396788..543f713 100644 --- a/asynq/decorators.py +++ b/asynq/decorators.py @@ -117,9 +117,7 @@ async def wrapped(*_args, **_kwargs): if exception is None: result = generator.send(send) else: - result = generator.throw( - type(exception), exception, exception.__traceback__ - ) + result = generator.throw(exception) except StopIteration as exc: return exc.value