-
Notifications
You must be signed in to change notification settings - Fork 258
Open
Description
In #408 we base the event loop on asyncio, which opens up the possibility to use async and await in tests. At this point, we cannot write actions or reactions as co-routines. Reactions can probably not be co-routines, since the state needs to be constant while processing (a batch of) reactions. But we can probably allow actions to be co-routines.
Implementation-wise, the event system will need to check whether an action-function is actually a co-routine and pass it to asyncio if it is. This will only work for PyComponents, unless we add some sort of async support to pyscript.
Reactions are currently unavailable