Official .wasm standard-library packages for Edge Python. Each capability is a Rust crate compiled to wasm32-unknown-unknown against the wasm-pdk ABI. Hosts load the resulting .wasm over the standard plugin contract, no custom embedder, no Rust on the consumer side.
tests/, agnostic Deno + Playwright runner driving the <edge-python> tag
<name>/, one folder per stdpkg crate, with src/, README.md, and <name>.json corpus
The folder name IS the package name IS the wasm artifact name (e.g. json/ -> json/target/wasm32-unknown-unknown/release/json.wasm). Each package's <name>.json sits alongside Cargo.toml; cases in it are automatically prefixed with from <name> import *\n before dispatch, so the corpus only contains the code being tested.
| Folder | Description |
|---|---|
json |
JSON serialization/deserialization, see json/README.md |
Each package builds independently; the agnostic runner asserts against the produced .wasm. From the repo root:
# Build every package's .wasm artifact.
( cd json && cargo build --release --target wasm32-unknown-unknown )
# One command, drives all corpora through the shared runner.
deno test --allow-all tests/The runner discovers packages by walking the repo root for <name>/<name>.json corpora. CI runs this matrix via .github/workflows/.
- Create
<name>/at the repo root withCargo.toml(name = "<name>",crate-type = ["cdylib"],wasm-pdkdep) and asrc/lib.rsexporting via#[plugin_fn]. - Drop
<name>/<name>.jsonwith the corpus (Edge Python source + expectedoutput/errorper case). - Run
cargo build --release --target wasm32-unknown-unknowninside the package folder. - Run
deno test --allow-all tests/from the repo root.
No edits to tests/.
MIT OR Apache-2.0