Closed bratanon closed 5 years ago
Thanks for finding this issue and listing your findings.
It appears the Queue does not process the cancellation until a message is next received. I've added a fix to the next release that should ensure cancellation occurs immediately.
Please let me know if there is still an issue after updating.
I have noticed a strange behavior when the app is shutting down. It can take over 30 seconds for it to do so.
I have debugged as good as I can, and from what I can tell there is something in the _translator::asyncloop that causes this.
The shutdown signal is catched, and
signal_shutdown
executed, but then it might take some time until you receive aasyncio.CancelledError
in the async_loop. Not sure why this might be that time consuming, but this is causing problem running this in a docker container as docker will send SIGKILL after 10 secounds if the container is not stopped or killed.I would really appreciate if you could find some time and take a look at this.