The Zenoh Python API
Project description
Eclipse Zenoh
The Eclipse Zenoh: Zero Overhead Pub/sub, Store/Query and Compute.
Zenoh (pronounce /zeno/) unifies data in motion, data at rest and computations. It carefully blends traditional pub/sub with geo-distributed storages, queries and computations, while retaining a level of time and space efficiency that is well beyond any of the mainstream stacks.
Check the website zenoh.io and the roadmap for more detailed information.
Python API
This repository provides a Python binding based on the main Zenoh implementation written in Rust.
How to install it
The Eclipse zenoh-python library is available on Pypi.org.
Install the latest available version using pip in a virtual environment:
pip install eclipse-zenoh
:warning:WARNING:warning: zenoh-python is developped in Rust.
On Pypi.org we provide binary wheels for the most common platforms (Linux x86_64, i686, ARMs, MacOS universal2 and Windows amd64). But also a source distribution package for other platforms.
However, for pip to be able to build this source distribution, there are some prerequisites:
pipversion 19.3.1 minimum (for full support of PEP 517). (if necessary upgrade it with command:'sudo pip install --upgrade pip')- Have a Rust toolchain installed (instructions at rustup.rs)
Supported Python versions and platforms
zenoh-python has been tested with Python 3.8, 3.9, 3.10, 3.11 and 3.12
It relies on the zenoh Rust API which require the full std library. See the list in Rust Platform Support.
Enable zenoh features
To enable some compilation features of the Rust library that are disabled by default, for example shared-memory, execute the following command:
pip install eclipse-zenoh --no-binary :all: --config-settings build-args="--features=zenoh/shared-memory"
How to build it
Requirements:
-
Python >= 3.8
-
pip >= 19.3.1
-
Rust and Cargo. If you already have the Rust toolchain installed, make sure it is up-to-date with:
rustup update
Recommended: Build with Virtual Environment
Using a virtual environment is strongly recommended to avoid Python version conflicts and dependency issues.
-
Create and activate a virtual environment:
python3 -m venv .venv source .venv/bin/activate # On Windows: .venv\Scripts\activate
-
Install development requirements:
pip install -r requirements-dev.txt
-
Build and install in development mode:
maturin develop --release
-
Run examples:
python examples/z_info.py
When you're done, deactivate the virtual environment:
deactivate
Alternative: Build without Virtual Environment
If you cannot use a virtual environment, follow these steps carefully:
-
Install development requirements:
pip install -r requirements-dev.txt
-
Ensure your system can find the building tool
maturin(installed by previous step). For example, it is placed at $HOME/.local/bin/maturin by default on Ubuntu 20.04.export PATH="$HOME/.local/bin:$PATH"
-
Build the wheel:
maturin build --release
-
Install the built wheel:
pip install ./target/wheels/*.whl --break-system-packages
:warning: Important: Systems may have multiple Python installations. Ensure you use the same
pipthat corresponds to thepython3you intend to use for running examples. You can verify this with:pip --version # Shows which Python version pip uses python3 --version # Shows which Python version python3 uses
If they don't match, use
python3 -m pip install ./target/wheels/*.whlinstead to ensure the package is installed for the correct Python version. -
Run examples using the same Python:
python3 examples/z_info.py
Building Documentation
To build the documentation locally:
-
Ensure you have zenoh-python installed (follow the build instructions above)
-
Install documentation requirements:
pip install -r docs/requirements.txt
-
Build the HTML documentation:
cd docs make html
-
Open the documentation:
open _build/html/index.html # macOS # or xdg-open _build/html/index.html # Linux # or navigate to docs/_build/html/index.html in your browser
The documentation is also available online at zenoh-python.readthedocs.io.
Running the Examples
You can install Zenoh Router first (See the instructions). Then, run the zenoh-python examples following the instructions in examples/README.md
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distributions
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file eclipse_zenoh-1.7.2.tar.gz.
File metadata
- Download URL: eclipse_zenoh-1.7.2.tar.gz
- Upload date:
- Size: 160.1 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.1.0 CPython/3.13.7
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
cfcbc3fc9eb001be2b7adc303f34ae22570ff2e0f942d51973bfd30f4ac37d6a
|
|
| MD5 |
144ee2dd116a00521976fc78dd546dda
|
|
| BLAKE2b-256 |
75099534eea23b59cee13b5430c7874f71c5e800d412ac04572517733812b8f3
|
File details
Details for the file eclipse_zenoh-1.7.2-pp310-pypy310_pp73-manylinux_2_28_aarch64.whl.
File metadata
- Download URL: eclipse_zenoh-1.7.2-pp310-pypy310_pp73-manylinux_2_28_aarch64.whl
- Upload date:
- Size: 9.4 MB
- Tags: PyPy, manylinux: glibc 2.28+ ARM64
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.1.0 CPython/3.13.7
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
75ce69656a6ef21d414a82b90980abfa2d0fc98607e7f051cf912673e98be08a
|
|
| MD5 |
4ee67b1069f4ba272d9e15abb3fbf165
|
|
| BLAKE2b-256 |
07d9cfe6b59de5b3d139ceb6277afef0f0a505524eb83bf1295d449edb53d641
|
File details
Details for the file eclipse_zenoh-1.7.2-pp310-pypy310_pp73-manylinux_2_17_armv7l.manylinux2014_armv7l.whl.
File metadata
- Download URL: eclipse_zenoh-1.7.2-pp310-pypy310_pp73-manylinux_2_17_armv7l.manylinux2014_armv7l.whl
- Upload date:
- Size: 9.3 MB
- Tags: PyPy, manylinux: glibc 2.17+ ARMv7l
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.1.0 CPython/3.13.7
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
9acfc65dbb83e94ed9c5f24f4539a045479948fa413ab4d33be99b06f7ae9da2
|
|
| MD5 |
7103c668e9166cd80298d1877538b730
|
|
| BLAKE2b-256 |
ad23229ebcb1554b068bf9aa56e4440b6d66e80458240fd8d7cb46f3b179ccef
|
File details
Details for the file eclipse_zenoh-1.7.2-pp39-pypy39_pp73-manylinux_2_28_aarch64.whl.
File metadata
- Download URL: eclipse_zenoh-1.7.2-pp39-pypy39_pp73-manylinux_2_28_aarch64.whl
- Upload date:
- Size: 9.4 MB
- Tags: PyPy, manylinux: glibc 2.28+ ARM64
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.1.0 CPython/3.13.7
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
0aff00541e849360d5854090853f9997a60583c803623a944e07e7c60af0b6b7
|
|
| MD5 |
d3175651e67cf8b94e95a70ba5019102
|
|
| BLAKE2b-256 |
6402018baf3f6a9edbde861014083fed61417189c649801644b88e9400116657
|
File details
Details for the file eclipse_zenoh-1.7.2-pp39-pypy39_pp73-manylinux_2_17_armv7l.manylinux2014_armv7l.whl.
File metadata
- Download URL: eclipse_zenoh-1.7.2-pp39-pypy39_pp73-manylinux_2_17_armv7l.manylinux2014_armv7l.whl
- Upload date:
- Size: 9.3 MB
- Tags: PyPy, manylinux: glibc 2.17+ ARMv7l
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.1.0 CPython/3.13.7
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
dbfac8f263d2c83026387dad501f8f8cb5add0f6089d5340d231ae5fcc5b55bd
|
|
| MD5 |
1cca129b24f993b79a34f98e734792eb
|
|
| BLAKE2b-256 |
81bbac3d7fea2167fcbe568084d4046c498dfa2b461740bc8eb0a0ce87971ded
|
File details
Details for the file eclipse_zenoh-1.7.2-cp39-abi3-win_amd64.whl.
File metadata
- Download URL: eclipse_zenoh-1.7.2-cp39-abi3-win_amd64.whl
- Upload date:
- Size: 7.9 MB
- Tags: CPython 3.9+, Windows x86-64
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.1.0 CPython/3.13.7
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
af3c857bcb964b000e770e3f758a8920e270ee32e79f67f25f845c51f258cc90
|
|
| MD5 |
bf74feee4533905947203108db4742ce
|
|
| BLAKE2b-256 |
d7d587a56e70a25fac485988efc45b27d7b31c2d228039dfef44e5ddd67fd343
|
File details
Details for the file eclipse_zenoh-1.7.2-cp39-abi3-manylinux_2_28_aarch64.whl.
File metadata
- Download URL: eclipse_zenoh-1.7.2-cp39-abi3-manylinux_2_28_aarch64.whl
- Upload date:
- Size: 9.4 MB
- Tags: CPython 3.9+, manylinux: glibc 2.28+ ARM64
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.1.0 CPython/3.13.7
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
07cf23f7de43a9008f9dd81bf5028a0459e43227087bc7838a0ba36c1eb232e7
|
|
| MD5 |
f329c53e215d7b0b93ddcf0f5fa82215
|
|
| BLAKE2b-256 |
8d4aad58417a73271e1a667b8bec1f6d42b500c0966c5e48a10c321e8c3f4634
|
File details
Details for the file eclipse_zenoh-1.7.2-cp39-abi3-manylinux_2_17_x86_64.manylinux2014_x86_64.whl.
File metadata
- Download URL: eclipse_zenoh-1.7.2-cp39-abi3-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
- Upload date:
- Size: 9.4 MB
- Tags: CPython 3.9+, manylinux: glibc 2.17+ x86-64
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.1.0 CPython/3.13.7
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
ede3dfb4072577e9a81f466364b9293be345801db9734bf0b3f7321194190035
|
|
| MD5 |
b359b377e03aee5110dc279800af5ad7
|
|
| BLAKE2b-256 |
638c39ea3c158ca403f3acb915dacd80787ac1afd0ce6d2be66a92d0dc2dd1ad
|
File details
Details for the file eclipse_zenoh-1.7.2-cp39-abi3-manylinux_2_17_i686.manylinux2014_i686.whl.
File metadata
- Download URL: eclipse_zenoh-1.7.2-cp39-abi3-manylinux_2_17_i686.manylinux2014_i686.whl
- Upload date:
- Size: 10.0 MB
- Tags: CPython 3.9+, manylinux: glibc 2.17+ i686
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.1.0 CPython/3.13.7
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
296885d49ef20e3e14777007e3ff519403ec4c0c9e4358b70bb2157985b29548
|
|
| MD5 |
5fb436afabf0f83f6101091241f9b4e7
|
|
| BLAKE2b-256 |
fe769520c1c583013bf8eefcd037c307615f5513592ba12166ec91fedefefbf0
|
File details
Details for the file eclipse_zenoh-1.7.2-cp39-abi3-manylinux_2_17_armv7l.manylinux2014_armv7l.whl.
File metadata
- Download URL: eclipse_zenoh-1.7.2-cp39-abi3-manylinux_2_17_armv7l.manylinux2014_armv7l.whl
- Upload date:
- Size: 9.3 MB
- Tags: CPython 3.9+, manylinux: glibc 2.17+ ARMv7l
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.1.0 CPython/3.13.7
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
8e53005eae75b3edac44d7f46d9678be784a67657f3dd871f5efabf351081a41
|
|
| MD5 |
04670b26ff018101da641863ab2aff29
|
|
| BLAKE2b-256 |
b4d3d1a7cfa1894baf801323423e56ab79fd17c39af922b6aad1a01aa5b4a57a
|
File details
Details for the file eclipse_zenoh-1.7.2-cp39-abi3-macosx_10_12_x86_64.whl.
File metadata
- Download URL: eclipse_zenoh-1.7.2-cp39-abi3-macosx_10_12_x86_64.whl
- Upload date:
- Size: 8.9 MB
- Tags: CPython 3.9+, macOS 10.12+ x86-64
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.1.0 CPython/3.13.7
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
7d0429933d9abeb70939a2cb02e32b8c8929651fd1762f1308b5fbd4ae41c3d9
|
|
| MD5 |
ad26dd7d6c703e5ecaf5b41da04a46a0
|
|
| BLAKE2b-256 |
068a6bb29455e16f119ec9db996d50f5ce40fdd7e1369fcfb6665144b50a0b7b
|
File details
Details for the file eclipse_zenoh-1.7.2-cp39-abi3-macosx_10_12_x86_64.macosx_11_0_arm64.macosx_10_12_universal2.whl.
File metadata
- Download URL: eclipse_zenoh-1.7.2-cp39-abi3-macosx_10_12_x86_64.macosx_11_0_arm64.macosx_10_12_universal2.whl
- Upload date:
- Size: 17.5 MB
- Tags: CPython 3.9+, macOS 10.12+ universal2 (ARM64, x86-64), macOS 10.12+ x86-64, macOS 11.0+ ARM64
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.1.0 CPython/3.13.7
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
d068c7ce2cb4f5ffe965f2d103f7173de732733a5102b6968313cedea1704694
|
|
| MD5 |
86417ced8480721311625621a4ef84e8
|
|
| BLAKE2b-256 |
7691484df5bdfd42102f9b5d99654c67f318d4967f3828dfd297d88c1262e143
|
File details
Details for the file eclipse_zenoh-1.7.2-cp39-abi3-linux_armv6l.whl.
File metadata
- Download URL: eclipse_zenoh-1.7.2-cp39-abi3-linux_armv6l.whl
- Upload date:
- Size: 9.4 MB
- Tags: CPython 3.9+
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.1.0 CPython/3.13.7
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
194ee61191a126e544b264587eb3659ae3952e9126e74d2d4a6e6f2ba163920a
|
|
| MD5 |
7ff0e6fc0265b0f53cd43c99e1f5c776
|
|
| BLAKE2b-256 |
8548a52169789207ff80f3b1d7f768c901fa117bd729ed665b37736b68ca2699
|