🐍⚡ pyodide-pool
Run Python callables and dask graphs in parallel on a pool of Pyodide Web Workers.
A single Pyodide interpreter is strictly single-threaded (no -pthread, no
fork), so parallelism means many interpreters. pyodide-pool is the
driver-side Python API for a pool of Web Workers (browser) or
worker_threads (Node), each hosting its own Pyodide interpreter:
submit— run one cloudpickled call on a worker and await its result.compute/get— an async dask scheduler that executesdask.delayed/dask.bag/ dask-array graphs in parallel on the pool.- Package mirroring — packages loaded in the driver (e.g. numpy) are installed on each worker on first use.
- Remote errors — the original Python exception is re-raised on the driver with the worker traceback chained.
The package runs only in the driver Pyodide instance; workers never install it. It is async-first: blocking the driver would starve the event loop the pool lives on.
Usage
import dask
import pyodide_pool
# In JupyterLite: import the JS bundle and start 4 nested workers
pool = await pyodide_pool.create_pool(pool_size=4)
value = await pyodide_pool.submit(fn, *args, **kwargs) # one remote call
total = await pyodide_pool.compute(dask.delayed(sum)([...])) # dask collections
create_pool loads the self-contained JS bundle from the JupyterLite site by
default; pass js_url= to load it from elsewhere. A web app that embeds
Pyodide can instead create the JS PyodidePool itself and register it with
pyodide.registerJsModule('js_pyodide_pool', { pool }).
Install pyodide-pool[dask] for compute / get.
For the multiprocessing-style API, see
wasm-multiprocessing.
Documentation
License
MIT
Metadata
Release files for pyodide-pool 0.1.3
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| pyodide_pool-0.1.3.tar.gz | 18.5 kB | Without provenance | Details for pyodide_pool-0.1.3.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| pyodide_pool-0.1.3-py3-none-any.whl | Python 3 | none | any | Details for pyodide_pool-0.1.3-py3-none-any.whl |
Total release size: 33.1 kB
Release files / pyodide_pool-0.1.3.tar.gz
| Download URL | pyodide_pool-0.1.3.tar.gz |
|---|---|
| Size | 18.5 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
0179352388dd13d5ceea481b9214547cdcad2ba14ef17d0746ecd9a7ddc1f6f8
|
|
BLAKE2b-256 checksum How to use checksums |
ac7bb6c7d3c749d19fcca75c766926a2f6e5cac9c3ad1b6e3f143386893175a5
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
uv/0.12.5 {"installer":{"name":"uv","version":"0.12.5","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Debian GNU/Linux","version":"13","id":"trixie","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}
|
Release files / pyodide_pool-0.1.3-py3-none-any.whl
| Download URL | pyodide_pool-0.1.3-py3-none-any.whl |
|---|---|
| Size | 14.7 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
59c9bdf50b92394687b4fcdeb043f687b78dcd2ebae369c1526e44471087796f
|
|
BLAKE2b-256 checksum How to use checksums |
febc3000fb82824359178c824df776fa12ff6463524ee59a2e02d1fcde7d1f6f
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
uv/0.12.5 {"installer":{"name":"uv","version":"0.12.5","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Debian GNU/Linux","version":"13","id":"trixie","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}
|
Security for pyodide-pool 0.1.3
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.