By: Ben Ruijl <ben@ruijl.ch>
fix spynso pyodide compilation Separate portable and native features through the Python adapter and HEP library, gate native evaluator exports and stubs, and add a WASM build check. Original user request: Fix the Python WASM compilation for spynso, so that it works with pyodide. ``` # One-time setup python3.14 -m venv .venv-wasm source .venv-wasm/bin/activate pip install pyodide-build==0.39.0 maturin==1.15.0 export PYODIDE_XBUILDENV_PATH="$HOME/.cache/symbolica-pyodide" pyodide xbuildenv install 314.0.7 export RUSTUP_TOOLCHAIN="$(pyodide config get rust_toolchain)" rustup toolchain install "$RUSTUP_TOOLCHAIN" \ --profile minimal --target wasm32-unknown-emscripten ``` ``` pyodide build . --outdir dist --no-isolation \ -C maturin.build-args="--locked --profile release-small \ --no-default-features --features wasm \ -- -C link-arg=-sEXPORTED_FUNCTIONS=_PyInit_core" ``` pyodide build . --outdir dist --no-isolation \ -C maturin.build-args="--locked --profile release-small \ --no-default-features --features wasm \ -- -C link-arg=-sEXPORTED_FUNCTIONS=_PyInit_core" Follow-up request: Create the PR
| Time to Start | Worker time | Duration | Time to finish | Idle | |
|---|---|---|---|---|---|
| Config | 2s | 15s | 15s | 17s | 2s |
| Eval | 15s | 50s | 50s | 1m06s | 0s |
| Build | 53s | 30m27s | - | - | 0s |
| Test | 1m07s | 2h09m41s | 14m48s | 15m55s | 0s |
| Deploy | - | - | - | - | 0s |
| Suite | 2s | 2h41m14s | - | - | 2s |