Replies: 2 comments 4 replies
-
|
Yes, the timeout is set from the point of view of the caller by design. If you want to limit how long your code takes then that's comparatively easier to add to your inner code. |
Beta Was this translation helpful? Give feedback.
0 replies
-
|
How would I implement that even just in the case of the example I posted above? Effectively, my setup is that I'm calling a function that may be rather quick but in exceptional cases may get stuck (hence the timeout from the time the actual computation starts) and I have control of the mirai block but I can't modify the code of the function called inside of it. |
Beta Was this translation helpful? Give feedback.
4 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
From my testing, it appears that a
.timeoutset when callingmirai()starts from the momentmirai()returns, independently of when the actual processing starts. For example, in the following case all processes time out, even though the last processes would have lasted less than the given timeout:Is there a way to set a timeout so that a process is stopped only when it has been actively working for more than a certain amount of time (independently of how long it may have waited in the queue)?
Beta Was this translation helpful? Give feedback.
All reactions