4 ms·
G’day, if anyone has any questions about this I’m happy to answer them here.
by benno128 3y ago
G’day, if anyone has any questions about this I’m happy to answer them here.
- jurynulifcation 3y agono questions, hope you're having a good day, cool idea!
- benno128 3y agoHaha thanks, you too!
- simonw 3y agoI tried this in your Python example: import sqlite3 >>> db = sqlite3.connect("data.db") Traceback (most recent call last): File "<stdin>", line 1, in <module> sqlite3.OperationalError: unable to open database file Presumably that operation failed because there isn't a writable virtual filesystem. Would it be possible to provide one?
- pseudosavant 3y agoWhat a novel way to integrate a bunch of web technologies! It makes me much more interested in using WASM.
- chii 3y agoI can imagine how a new style of web-only terminals be possible. The filesystem is realistically _any_ url, and you can load any wasi programs (via a shell, which is also just another wasi program). I wonder if this is practical, or just a gimmicky way to use a computer...
- benno128 3y agoThanks! Yeah WebAssembly has an exciting future ahead of it.
- bantunes 3y agoWould it be practical to output HTML from these WASI components and build a page from them?
- benno128 3y agoI wouldn't put it in prod, but it would be possible. You'd need a JS binding layer that dealt with the output and wrote it to the page, but it could be minimal. There are other projects that are targeted more at this kind of thing if you want dynamic access to the DOM from Web Assembly (sorry I don't know them off the top of my head).
- Zetaphor 3y agoUnfortunately this page doesn't load in Firefox on Linux
- Zetaphor 3y agoAlso just tested in Chromium, doesn't seem to work for me on Fedora Linux. Just locks up the browser
- tarasglek 3y agoHi, I already support typescript execution in http://chatcraft.org/ http://chatcraft.org/ via wasm esbuild. Runno is really cool as it will also lets me support intepreted languages like Python and maybe even golang(assuming i can have a wasi binary produce another wasi binary). From docs: Currently @runno/wasi supports running only unstable and snapshot-preview1 WASI binaries. The snapshot-preview1 standard is more recent, and preferred. Where does one see what's part of snapshot-preview1? My google-foo is failing me.
- benno128 3y agoSnapshot Preview 1 is the standard all tools are building to right now. The specification is available here: https://github.com/WebAssembly/WASI/blob/main/legacy/preview1/docs.md https://github.com/WebAssembly/WASI/blob/main/legacy/preview... It's pretty unreadable though! Preview 2 looks like it will be a big change, and is just being finalised at the moment. I'd expect that when preview 2 is available there will be an improvement in the quality of documentation. I'm not sure how long it will take after release for tools to start switching to it. I'd expect Preview 1 will still be the main target at least for the rest of this year.