Eclipse zenoh Python API
Eclipse zenoh is an extremely efficient and fault-tolerant Named Data Networking (NDN) protocol that is able to scale down to extremely constrainded devices and networks.
How to install it
The Eclipse zenoh-python library is available on Pypi.org.
Install the latest available version using pip
:
pip install eclipse-zenoh
![warning](https://github.githubassets.com/images/icons/emoji/unicode/26a0.png =20x20)WARNING![warning](https://github.githubassets.com/images/icons/emoji/unicode/26a0.png =20x20) zenoh-python is developped in Rust. On Pypi.org we provide binary wheels for the most common platforms (MacOS, Linux x86). But also a source distribution package for other platforms.
However, for pip
to be able to build this source distribution, there some prerequisites:
pip
version 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 https://rustup.rs/)
Supported Python versions and platforms
zenoh-python has been tested with Python 3.6, 3.7, 3.8 and 3.9.
It relies on the zenoh Rust API which require the full std
library. See the list Rust supported platforms here: https://doc.rust-lang.org/nightly/rustc/platform-support.html .
Currently only the following platforms have been tested:
- Linux
- MacOS X
How to build it
Requirements:
-
Python >= 3.5
-
Rust and Cargo. Then install the nighlty toolchain running:
rustup toolchain install nightly
-
maturin. Install it with:
pip install maturin
Steps:
-
Make sure your shell is running in a Python virtual environment.
-
Build zenoh-python using maturin
cd zenoh-python maturin develop --release
Maturin will automatically build the zenoh Rust API, as well as the zenoh-python API and install it in your Python virtual environement.