I have this weird bug in 17.0.3, I have a set a callback that yields until it reaches a max or final value. If this value is reached it returns a trap::interrupt error. Everything seems fine but as soon as a timeout each time I create a new sandbox and invoke a function on it, it seems like it tells me "cannot enter component instance" thought I would ask if anyone has seen anything similar?
After a component instance traps it is no longer usable
Even if it is a new sandbox? I guess I could just change the type of error returned
Could you expand on what you mean by "new sandbox"? The key type here in wasmtime would be the Instance
Oh yes sorry about that. A new instance being built from a preinit-module
That should be fine. The error you are seeing means that the component has been entered and not "cleanly" exited; trapping would be the most obvious reason for that in this case :shrug:
Are you able to reproduce this issue on the latest wasmtime release?
(I doubt this is a wasmtime bug, but if it is then upgrading would be the first step)
I see, awesome. I will see if this goes away if I just use another error type. We are a bit gated to this version, but I think I will convince them to move. Need all these nice new features anyway.
I have a set a callback that yields until it reaches a max or final value. If this value is reached it returns a trap::interrupt error.
Another thought: are you sure this value is being reset for each instance? If it is tracked as part of the Store<T>
data (T
) and the Store
is reused between instances that value wouldn't automatically be reset for a new instance
I think I create a store for each new instance but I should investigate if there is any reuse happening somewhere
Last updated: Dec 23 2024 at 13:07 UTC