Wasmer seems to support WASI, but I'm not sure how to use WASI through wasmer.hh
We haven't exposed WASI through the c-api yet, but we will soon! 🙂
Are there any time constraints on when you will need that? (to make sure we fulfill them!)
Not super urgent. Some time in the next couple of months would be great. How much work do you think it will be?
It depends on which features we need to support; our Rust WASI API supports creating virtual files with arbitrary backing logic that can be swapped with files at runtime (_and_ these virtual files can be safely serialized and deserialized allowing for snapshots of the filesystem) -- that's something that will require some solid design work to make portable and nice to use across languages. We haven't started that design work yet because this Rust WASI FS API is relatively new and we're waiting for more feedback before porting it.
But for general execution of WASI, there's only one blocker on the WASI side that I'm aware of. It has to do with the WASI state owning filesystem resources directly which means that our state creation function can't safely be run twice because they'll fight over filesystem resources. This is somewhat of an edge case though and something that's near the top of my todo list to fix.
It's my understanding that we could probably get this "working" on the C-side pretty quickly -- I don't have full context on exactly what we expose, so it may require extra work to make it nice/properly usable which is why I put "working" in scare quotes.
Thanks for the quick responses. Off the top of my head I can't think of any advanced features we'll need, but I'll confirm with my team.
I've talked to my team, and we don't need any advanced features. We will need to import our own functions in addition to WASI, but other than that the default behavior should be fine.
Sorry about the delay! A lot of things kept coming up, but it just merged into master #856 .
Let us know if you run into any issues with it and we'll quickly fix them for you!
The API looks good. I'll give it a try once it's released. Thanks.
This is shipping in 0.10.0 which is in the process of being released now. Feel free to reopen or create a new issue if there are any problems!
Most helpful comment
I've talked to my team, and we don't need any advanced features. We will need to import our own functions in addition to WASI, but other than that the default behavior should be fine.