You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
If a BaseException which is not an Exception is thrown inside a job (for example, KeyboardInterrupt), the Scheduler._wait_failed() task fails to catch this exception after re-raising it, and this exception gets raised from the Scheduler.close() method (due to await self._failed_task), which is totally unexpected.
Probably the intended invariant in Scheduler._wait_failed() was to never raise an exception.
The text was updated successfully, but these errors were encountered:
No, the application has already received the KeyboardInterrupt (by awaiting the job future), and is in the process of graceful shutdown (in the exception handler). In the process of the shutdown it calls Scheduler.close(), which unexpectedly raises anotherKeyboardInterrupt, which then aborts the graceful termination.
I have a feeling that the problem should be fixed by asyncio itself somehow, not by aiojobs.
Otherwise, every asyncio library should catch and process KeyboardInterrupt on every await expression.
If a
BaseException
which is not anException
is thrown inside a job (for example,KeyboardInterrupt
), theScheduler._wait_failed()
task fails to catch this exception after re-raising it, and this exception gets raised from theScheduler.close()
method (due toawait self._failed_task
), which is totally unexpected.Probably the intended invariant in
Scheduler._wait_failed()
was to never raise an exception.The text was updated successfully, but these errors were encountered: