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
Let there bei 2 tasks A and B, with A repeatedly sleeping for short intervals (e.g. 0.1s) and B sleeping once for a longer interval (5s). So one Execution of B spans multiple executions of A.
So the callback queue looks like this:
A (0.1s)
B (5s)
Now, when fast-forwarding to 10s, A is popped from the queue first. It schedules another A after 0.1s, which ist still way before the first run of B. But before ist is actually executed, B is popped as well! The next sleep(0.1) issued by A should be executed before B.
Is there any way to make this work, I.e. handle a Tasks that might schedule another task? This would better match the topology of a real-time event queue. (This was tested with Python 3.7.3).
The text was updated successfully, but these errors were encountered:
Let there bei 2 tasks A and B, with A repeatedly sleeping for short intervals (e.g. 0.1s) and B sleeping once for a longer interval (5s). So one Execution of B spans multiple executions of A.
So the callback queue looks like this:
Now, when fast-forwarding to 10s, A is popped from the queue first. It schedules another A after 0.1s, which ist still way before the first run of B. But before ist is actually executed, B is popped as well! The next sleep(0.1) issued by A should be executed before B.
Is there any way to make this work, I.e. handle a Tasks that might schedule another task? This would better match the topology of a real-time event queue. (This was tested with Python 3.7.3).
The text was updated successfully, but these errors were encountered: