From f92aa1869715e14895657f4fe1c5e319a5525dba Mon Sep 17 00:00:00 2001 From: Miguel Elizalde Date: Sun, 11 Jan 2026 17:02:19 -0700 Subject: [PATCH 1/2] fix: update README to clarify compatibility with Wasmtime versions --- README.md | 11 +++++++---- 1 file changed, 7 insertions(+), 4 deletions(-) diff --git a/README.md b/README.md index 3cd1778..e017744 100644 --- a/README.md +++ b/README.md @@ -3,7 +3,7 @@ **A [Bytecode Alliance](https://bytecodealliance.org/) project** This is a tool to convert a Python application to a [WebAssembly -component](https://github.com/WebAssembly/component-model). It takes the +component](https://github.com/WebAssembly/component-model). It takes the following as input: - a [WIT](https://github.com/WebAssembly/component-model/blob/main/design/mvp/WIT.md) file or directory @@ -17,7 +17,7 @@ e.g. [`wasmtime`](https://github.com/bytecodealliance/wasmtime). ## Getting Started First, install [Python 3.10 or later](https://www.python.org/) and -[pip](https://pypi.org/project/pip/) if you don't already have them. Then, +[pip](https://pypi.org/project/pip/) if you don't already have them. Then, install `componentize-py`: ```shell @@ -62,6 +62,9 @@ componentize-py -d hello.wit -w hello componentize --stub-wasi app -o app.wasm To test it, you can install `wasmtime-py` and use it to generate host-side bindings for the component: +> [!NOTE] +> Due to compatibility issues with `wasmtime` versions beyond 38.x, **this example** requires version 38.0.0 or earlier: `pip install "wasmtime==38.0.0"` + ```shell pip install wasmtime python3 -m wasmtime.bindgen app.wasm --out-dir hello_host @@ -99,7 +102,7 @@ created. Currently, the application can only import dependencies during build time, which means any imports used at runtime must be resolved at the top level of the -application module. For example, if `x` is a module with a submodule named `y` +application module. For example, if `x` is a module with a submodule named `y` the following may not work: ```python @@ -110,7 +113,7 @@ class Hello(hello.Hello): return x.y.foo() ``` -That's because importing `x` does not necessarily resolve `y`. This can be +That's because importing `x` does not necessarily resolve `y`. This can be addressed by modifying the code to import `y` at the top level of the file: ```python From efb6b530ed251bb220e6fa7c51e5c3a202944cf6 Mon Sep 17 00:00:00 2001 From: Miguel Elizalde Date: Mon, 12 Jan 2026 10:56:40 -0700 Subject: [PATCH 2/2] fix: correct reference to wasmtime-py in compatibility note --- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.md b/README.md index e017744..d7ecd70 100644 --- a/README.md +++ b/README.md @@ -63,7 +63,7 @@ To test it, you can install `wasmtime-py` and use it to generate host-side bindings for the component: > [!NOTE] -> Due to compatibility issues with `wasmtime` versions beyond 38.x, **this example** requires version 38.0.0 or earlier: `pip install "wasmtime==38.0.0"` +> Due to compatibility issues with `wasmtime-py` versions beyond 38.x, **this example** requires version 38.0.0 or earlier: `pip install "wasmtime==38.0.0"` ```shell pip install wasmtime