Skip to content

Conversation

@kakyoism
Copy link

@kakyoism kakyoism commented Jun 30, 2021

With current waapi-client, we get an error looking like this

 RuntimeError: There is no current event loop in thread 'ThreadPoolExecutor-0_0'.

when the caller process already uses an asyncio event loop.

So to solve this problem, I had to use this patch locally.
Hope this patch helps with a sound solution to this scenario, which could happen often if external IPC is involved on the WAAPI caller side.

@kakyoism
Copy link
Author

I'm not entirely sure about commit 0b0ef8c8668e1d54ca27582d2827efdf7e5ca76a, but I think the event loop will not close itself on bailouts due to runtime errors, so I took some cautions there. Feel free to correct me if I'm wrong, please.

@ak-slongchamps ak-slongchamps marked this pull request as draft September 2, 2021 13:08
@ak-slongchamps
Copy link
Collaborator

Moving to draft: larger work needed for graceful termination when multiple async loops are involved.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants