bytecodealliance / componentize-py

Apache License 2.0
157 stars 19 forks source link

experimental `isyswasfa` support; (re)add `--stub-wasi` #79

Closed dicej closed 8 months ago

dicej commented 8 months ago

(re)add --stub-wasi option

Early versions of this project had such an option, but I had to drop as part of the refactoring required to support native extensions. The implementation is a bit tricky, since we need to import WASI during pre-initialization, but then stub out the imports in the final component. Normally, that would require significant surgery on the pre-initialized component, but I've "cheated" by applying the state snapshot to a stubbed component instead of the original one.

experimental isyswasfa support

This adds support for isyswasfa, which serves as a polyfill for WASI 0.3-style composable concurrency on WASI 0.2 runtimes. I'm planning to replace this with proper component model async support once it's available.