Other work: autograd
, and the PyBaMM ecosystem (Python Battery Mathematical Modelling)
scikit-build-core
as a new build backendIronPython
IronPython
GraalPy
RustPython
wasm32-emscripten
) via LLVMemcc
, as a drop-in replacement for gcc
Python/JavaScript
Foreign function interface
WebAssembly + JavaScript stdlib
{
Glue code
micropip
(CDN)
225+ packages!
(PyPI)
pure Python wheels
and essential low-level libraries
A game made using pygame-ce
and SDL2
Play along!
https://agriyakhetarpal.github.io/sudoku/ – (works better on laptops)
https://diataxis.fr/
Diátaxis, from the Ancient Greek δῐᾰ́τᾰξῐς: dia (across) and taxis (arrangement).
New entrant to the Jupyter ecosystem!
threading
or multiprocessing
socket
from the stdlib)Most of them are now built against WASM in CI, and all of them run in Pyodide!
pytest
, or other test runnersStart
Check out sources
Set up
Python and Emscripten
pyodide build
Invoke
Run tests
Install Node.js
End
{distribution}-{version}-{python tag}-{abi tag}-{platform tag}.whl
Pure Python wheels are named mypackage-0.1.0-py3-none-any.whl
Compiled wheels get tagged as
mypackage-0.1.0-cp312-cp312-emscripten_3_1_58-wasm32.whl
i.e., reflecting the Emscripten version in the ABI tag. This has now changed to pyodide_20XY_Z
to reflect the current year and build number.
jupyterlite-sphinx
A Sphinx
extension providing a set of utilities to convert doctest-based examples to notebooks
provides a Pyodide kernel for those notebooks, to install WASM wheels
Simply add the .. try_examples
::
reST stub to your example's docstring:
>>> x = 2 >>> y = 2 >>> x + y 4
and a button in the HTML source is generated for you!
pip install "jupyterlite-sphinx" "jupyterlite-pyodide-kernel"
Another kernel, jupyterlite-xeus
is available as well, which works with emscripten-forge
recipes.
Please feel free to say hello!
in/agriyakhetarpal
agriyakhetarpal
agriyakhetarpal
agriyakhetarpal [at] outlook [dot] com
Content licensed under the CC-by-SA Attribution-ShareAlike Version 4.0 International License
Special thanks to
Ralf Gommers
Albert Steppi
Melissa Mendonça
Matthias Bussonnier
Robert Hood Chatham
Gyeongjae Choi
Loïc Estève
...and to many more in my journey
Emoji by openmoji.org
These slides
Pyodide
@agriyakhetarpal@fosstodon.org
@agriyakhetarpal.bsky.social