Eclipse Cyclone DDS Python binding
Project description
Python binding for Eclipse Cyclone DDS
A Python binding for Eclipse Cyclone DDS.
Getting Started
Eclipse CycloneDDS Python requires Python version 3.7 or higher. You can install with included Cyclone DDS binaries or leveraging an existing Cyclone DDS installation by installing from source via PyPi.
Documentation can be found on the cyclonedds.io website: Python API docs
Installing with pre-built Cyclone DDS binaries
This is the most straightforward method to install Cyclone DDS Python, but there are a couple of caveats. The pre-built package:
- has no support for DDS Security,
- has no support for shared memory via Iceoryx,
- comes with generic Cyclone DDS binaries that are not optimized per-platform.
If these are of concern, proceed with an installation from source. If not, running this installation is as simple as:
$ pip install cyclonedds
You can also use the nightly build stream instead, which is built from the master
branches of cyclonedds
and cyclonedds-python
. This will always get you the latest and greatest, but less stable version that might contain API breaks.
$ pip install cyclonedds-nightly
Installing from source
When installing from source you can make use of the full list of features offered by Cyclone DDS. First install Cyclone DDS as normal. Then continue by setting the CYCLONEDDS_HOME
environment variable to the installation location of Cyclone DDS, which is the same as what was used for CMAKE_INSTALL_PREFIX
. You will have to have this variable active any time you run Python code that depends on cyclonedds
so adding it to .bashrc
on Linux, ~/bash_profile
on MacOS or the System Variables in Windows can be helpful. This also allows you to switch, move or update Cyclone DDS without recompiling the Python package.
You'll need the Python development headers to complete the install. If using apt
, try sudo apt install python3-dev
. For other distributions, see this comment.
via PyPi
You can install the source from the latest release from Pypi, or use a tag to get a specific version. A full example (for linux) is shown below
$ git clone https://github.com/eclipse-cyclonedds/cyclonedds
$ cd cyclonedds && mkdir build install && cd build
$ cmake .. -DCMAKE_INSTALL_PREFIX=../install
$ cmake --build . --target install
$ cd ..
$ export CYCLONEDDS_HOME="$(pwd)/install"
$ pip3 install cyclonedds --no-binary cyclonedds
via git
A full example installation of the quickest way to get started via git is shown below:
$ git clone https://github.com/eclipse-cyclonedds/cyclonedds
$ cd cyclonedds && mkdir build install && cd build
$ cmake .. -DCMAKE_INSTALL_PREFIX=../install
$ cmake --build . --target install
$ cd ..
$ export CYCLONEDDS_HOME="$(pwd)/install"
$ pip3 install git+https://github.com/eclipse-cyclonedds/cyclonedds-python
Command line tooling
The Python package contains a suite of command line tools, all nested under the main entrypoint cyclonedds
. The main help screen shows the commands available:
cyclonedds ls
The ls
subcommand shows you the entities in your DDS system and their QoS settings. For example, here is the output when running the Vehicle
example from this repo in the background:
cyclonedds ps
The ps
subcommand shows you the applications in your DDS system. Note that this depends on so called 'Participant Properties', tactfully named QoS properties in DDS participants. These were merged into CycloneDDS for version 0.10.0. Here is an example of the output when running the Vehicle
example from this repo in the background on a single host:
cyclonedds typeof
The typeof
subcommand shows you the type(s) of a topic in your system. With XTypes it can happen that more than one type for each topic exists and that they are still compatible. The types are represented in IDL. Here is an example of the output when running the Vehicle
example:
cyclonedds subscribe
The subscribe
subcommand dynamically subscribes to a topic and shows you the data as it arrives. The type is discovered in a similar manner as typeof
. Here is an example of the output when running the Vehicle
example:
cyclonedds publish
The publish
subcommand dynamically builds a REPL with datatypes and a writer for a topic and shows you the data as it arrives. The type is discovered in a similar manner as typeof
.
cyclonedds performance
The performance
subcommand is a nicer frontend to ddsperf
with four modes: publish
, subscribe
, ping
and pong
. The below performance run example is the cyclonedds performance subscribe
mode rendered with cyclonedds performance publish
running in the background.
Contributing
We very much welcome all contributions to the project, whether that is questions, examples, bug fixes, enhancements or improvements to the documentation, or anything else really. When considering contributing code, it might be good to know that build configurations for Azure pipelines are present in the repository and that there is a test suite using pytest, along with flake8 code linting, and documentation built with sphinx. Be sure to install with the Extra dependencies if you're going to run tests, lints or build the docs.
You can run the test suite and linting using the local-ci.py script in this repo.
$ python local-ci.py
Or lint a single file/directory (as the whole repo can be a little noisey) using:
$ python -m flake8 path/to/some_file.py
You can build and serve the documentation (at http://localhost:8000/) using:
cd docs
python -m sphinx source/ _build/
# Serve the HTML files to view at localhost:8000
python -m http.server -d _build
Extra dependencies
The cyclonedds
package defines two sets of optional dependencies, dev
and docs
, used for developing cyclonedds
and building the documentation, respectively. If you want to install with development tools add the component to your installation, for example:
$ pip3 install --user "cyclonedds[dev] @ git+https://github.com/eclipse-cyclonedds/cyclonedds-python"
Or when installing from a local git clone, which is recommended when developing or building the docs:
$ cd /path/to/git/clone
# for development:
$ pip3 install --user ".[dev]"
# for documentation generation
$ pip3 install --user ".[docs]"
# or for both
$ pip3 install --user ".[dev,docs]"
For more information see the packaging guide information on optional dependencies.
PyOxidizer build
You can build a self-contained binary of the cyclonedds
CLI tool using PyOxidizer. It should be as simple as:
$ cd /path/to/git/clone
$ pip3 install --user pyoxidizer
$ pyoxidizer build
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
File details
Details for the file cyclonedds-nightly-2022.11.4.tar.gz
.
File metadata
- Download URL: cyclonedds-nightly-2022.11.4.tar.gz
- Upload date:
- Size: 160.8 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.1 CPython/3.9.15
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 524a249ccf0ddda1ee2ba2d93ac66cbcef70b7485e9e60f6b3c7befdd10953db |
|
MD5 | 3c58acc167e3cb49e28d1c40dccc7ba3 |
|
BLAKE2b-256 | 4a57ef676bc2a3a92ee6e8ebc37840b045bd5cdedc6d95c33311e52caafd267e |
File details
Details for the file cyclonedds_nightly-2022.11.4-cp310-cp310-win_amd64.whl
.
File metadata
- Download URL: cyclonedds_nightly-2022.11.4-cp310-cp310-win_amd64.whl
- Upload date:
- Size: 2.3 MB
- Tags: CPython 3.10, Windows x86-64
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.1 CPython/3.9.15
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | a16568ff726dd1e9cdb9d3c81a5c46ae91d953a297e3cf3f41494d6b6d87fe20 |
|
MD5 | d96642656c0cca8348d96a8e0f7605e4 |
|
BLAKE2b-256 | 565e116ed32286dc2c3636b213b3e8fdf2b6058e9e017b98680d196679648a7c |
File details
Details for the file cyclonedds_nightly-2022.11.4-cp310-cp310-musllinux_1_1_x86_64.whl
.
File metadata
- Download URL: cyclonedds_nightly-2022.11.4-cp310-cp310-musllinux_1_1_x86_64.whl
- Upload date:
- Size: 6.6 MB
- Tags: CPython 3.10, musllinux: musl 1.1+ x86-64
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.1 CPython/3.9.15
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 487f5de723e6851c4b2b5a000b5c5530e8b1b5ca430fb46b1c49b5c2f31e3c32 |
|
MD5 | 595da01618cd1a07c7843bf29916be5c |
|
BLAKE2b-256 | 2a99987a4906f19e06c9e5f0a03e6ef9499b19fa266e900924c43c97488a76d6 |
File details
Details for the file cyclonedds_nightly-2022.11.4-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
.
File metadata
- Download URL: cyclonedds_nightly-2022.11.4-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
- Upload date:
- Size: 6.6 MB
- Tags: CPython 3.10, manylinux: glibc 2.17+ x86-64
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.1 CPython/3.9.15
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 531e864b3fea21fa07bf3e69d589b5b64dd16926cc641b4490283ca6a006c5e0 |
|
MD5 | 30eb9bfcd25c02da0e48e69f12126616 |
|
BLAKE2b-256 | 07f2a25d36f272d0a076edc7be204b16ba362a59ab0da288f51a0cd7510bc373 |
File details
Details for the file cyclonedds_nightly-2022.11.4-cp310-cp310-macosx_11_0_arm64.whl
.
File metadata
- Download URL: cyclonedds_nightly-2022.11.4-cp310-cp310-macosx_11_0_arm64.whl
- Upload date:
- Size: 789.4 kB
- Tags: CPython 3.10, macOS 11.0+ ARM64
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.1 CPython/3.9.15
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 2df5f9a43ece74cb8f10879f282cc9a6fcfdeccbe39697ce0b2a5ba01bd94392 |
|
MD5 | e969ad5d6a384558d10925400bcb41b1 |
|
BLAKE2b-256 | b95e881791fd3c4d53a93051b6050fdb08f0c2f773867cf2ee2a1969e6278ddd |
File details
Details for the file cyclonedds_nightly-2022.11.4-cp310-cp310-macosx_10_9_x86_64.whl
.
File metadata
- Download URL: cyclonedds_nightly-2022.11.4-cp310-cp310-macosx_10_9_x86_64.whl
- Upload date:
- Size: 856.4 kB
- Tags: CPython 3.10, macOS 10.9+ x86-64
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.1 CPython/3.9.15
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 646110e9f7e43cf8d9175e9d164f71ea24863d3706b1fbf5ec7d67cb92fcee1f |
|
MD5 | d9871321b6d729c92c9fd5643fff21af |
|
BLAKE2b-256 | bf26ea983360623d2a36d12c2eac83509ef4c55e3dbd941201d082fb10179168 |
File details
Details for the file cyclonedds_nightly-2022.11.4-cp39-cp39-win_amd64.whl
.
File metadata
- Download URL: cyclonedds_nightly-2022.11.4-cp39-cp39-win_amd64.whl
- Upload date:
- Size: 2.3 MB
- Tags: CPython 3.9, Windows x86-64
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.1 CPython/3.9.15
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | b18dd2b9f468d069094d8c0a98a7c8fcb1de66028f9ee42a644502c6adee9148 |
|
MD5 | 8bcf4e5dd1ece9ecb1576d6663f5382a |
|
BLAKE2b-256 | 3d744f3b423ed4b3b9bc3ea57fada579c3a5fbf48f3633f01145e25e36916ce5 |
File details
Details for the file cyclonedds_nightly-2022.11.4-cp39-cp39-musllinux_1_1_x86_64.whl
.
File metadata
- Download URL: cyclonedds_nightly-2022.11.4-cp39-cp39-musllinux_1_1_x86_64.whl
- Upload date:
- Size: 6.6 MB
- Tags: CPython 3.9, musllinux: musl 1.1+ x86-64
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.1 CPython/3.9.15
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 61a505f591f65f44228b840ebc892306b322169282a408c9c127e1498af4f327 |
|
MD5 | 1f277008d07932dac09cc3fb0c2515de |
|
BLAKE2b-256 | 932c1d9350fc27c6b68987589c0456563b3b30db8efd2e20c283ba8127783216 |
File details
Details for the file cyclonedds_nightly-2022.11.4-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
.
File metadata
- Download URL: cyclonedds_nightly-2022.11.4-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
- Upload date:
- Size: 6.6 MB
- Tags: CPython 3.9, manylinux: glibc 2.17+ x86-64
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.1 CPython/3.9.15
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 23ccef403cc2a88e6183cd16119f101f9424060c70bb736c1e061a957693c162 |
|
MD5 | 112b27519822ebc30473a49af2fdd341 |
|
BLAKE2b-256 | 54afb14f52c20426a2effee877e3d4c711b3882b384f1da4f4ef374983807971 |
File details
Details for the file cyclonedds_nightly-2022.11.4-cp39-cp39-macosx_11_0_arm64.whl
.
File metadata
- Download URL: cyclonedds_nightly-2022.11.4-cp39-cp39-macosx_11_0_arm64.whl
- Upload date:
- Size: 789.4 kB
- Tags: CPython 3.9, macOS 11.0+ ARM64
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.1 CPython/3.9.15
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 17938081a851c26c65f623e5decbf6516691f0ade32bd18433b86832f2595036 |
|
MD5 | 8499dc3ae7893a0031e4bcbb89ee635b |
|
BLAKE2b-256 | 594e42796ba61b2e4dcbef03a25a60c0682a8bf3b898c11830e45004ac7bd10a |
File details
Details for the file cyclonedds_nightly-2022.11.4-cp39-cp39-macosx_10_9_x86_64.whl
.
File metadata
- Download URL: cyclonedds_nightly-2022.11.4-cp39-cp39-macosx_10_9_x86_64.whl
- Upload date:
- Size: 856.4 kB
- Tags: CPython 3.9, macOS 10.9+ x86-64
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.1 CPython/3.9.15
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 06f211bb5eb03d0866948aee20eca0b9ce1649bb97a92e186c022fe5b672c422 |
|
MD5 | 62f5187788172a91d5c55d68807ec991 |
|
BLAKE2b-256 | da46cb74a8a66f3e1668766448bed5cc1428a02e7adc2affe71d25b229b00189 |
File details
Details for the file cyclonedds_nightly-2022.11.4-cp38-cp38-win_amd64.whl
.
File metadata
- Download URL: cyclonedds_nightly-2022.11.4-cp38-cp38-win_amd64.whl
- Upload date:
- Size: 2.3 MB
- Tags: CPython 3.8, Windows x86-64
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.1 CPython/3.9.15
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | cc6ca8db1edec56479f5f59f6620c88ed5041a7f17f38a591348e4673084c6c8 |
|
MD5 | 16e31e4aca8f577493fbb3ab52bfa9eb |
|
BLAKE2b-256 | 6ade8f7145fb0a90ca17c237c33e038ff0aff5e4c2128c0a9f136afed8163828 |
File details
Details for the file cyclonedds_nightly-2022.11.4-cp38-cp38-musllinux_1_1_x86_64.whl
.
File metadata
- Download URL: cyclonedds_nightly-2022.11.4-cp38-cp38-musllinux_1_1_x86_64.whl
- Upload date:
- Size: 6.6 MB
- Tags: CPython 3.8, musllinux: musl 1.1+ x86-64
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.1 CPython/3.9.15
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 2690c2e4f2bdeea5b405d1a3cbaabe4ca77118422ae445d2cb13037fd961af98 |
|
MD5 | 17a079610809550db2ff2e039fb4fe87 |
|
BLAKE2b-256 | 7f671709acf01fd45c856b67cea7b2efcd2ba7cf4c69067e9066808a4318fb6d |
File details
Details for the file cyclonedds_nightly-2022.11.4-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
.
File metadata
- Download URL: cyclonedds_nightly-2022.11.4-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
- Upload date:
- Size: 6.6 MB
- Tags: CPython 3.8, manylinux: glibc 2.17+ x86-64
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.1 CPython/3.9.15
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 5fa2196b021e3b59a157218f887cd35e409d0bd4a6ba058760840fc3dbf337a6 |
|
MD5 | 8102331fad963b57a8e4505cb10d7a08 |
|
BLAKE2b-256 | 3d5c440bf8e7b017d6d83d07f391f9163b785745659fad598f27a62fcb3ea7d2 |
File details
Details for the file cyclonedds_nightly-2022.11.4-cp38-cp38-macosx_11_0_arm64.whl
.
File metadata
- Download URL: cyclonedds_nightly-2022.11.4-cp38-cp38-macosx_11_0_arm64.whl
- Upload date:
- Size: 789.4 kB
- Tags: CPython 3.8, macOS 11.0+ ARM64
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.1 CPython/3.9.15
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 0714de6ddfb05d6946d704d67a4e71d8767de13463680ac6eec202c827d9cb02 |
|
MD5 | b3548f8d7483e4034d69f0cc04ac018d |
|
BLAKE2b-256 | af6921c17b7c3ba53997f30f8bc093878380ad91bb80656170d9f7f9bfaf4392 |
File details
Details for the file cyclonedds_nightly-2022.11.4-cp38-cp38-macosx_10_9_x86_64.whl
.
File metadata
- Download URL: cyclonedds_nightly-2022.11.4-cp38-cp38-macosx_10_9_x86_64.whl
- Upload date:
- Size: 856.4 kB
- Tags: CPython 3.8, macOS 10.9+ x86-64
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.1 CPython/3.9.15
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 2b452dcd5578b64ea39f2b1011af96adf4b3dcce34e54c91659d54439883e0a1 |
|
MD5 | 6ff5115744d044b2af5b5ae562193c3f |
|
BLAKE2b-256 | 9becd216e24a151c67bb74285bf4c57a52fca2f17ac15a8aea859c53201c8ee6 |
File details
Details for the file cyclonedds_nightly-2022.11.4-cp37-cp37m-win_amd64.whl
.
File metadata
- Download URL: cyclonedds_nightly-2022.11.4-cp37-cp37m-win_amd64.whl
- Upload date:
- Size: 2.3 MB
- Tags: CPython 3.7m, Windows x86-64
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.1 CPython/3.9.15
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 257577a6cb3d69ecacd0a607e2840878ccd4d634998d308ffe2a378f070fabbf |
|
MD5 | 4f9528d7b39f645dce372ef461565cf9 |
|
BLAKE2b-256 | 9fa39670c7397b4dd7599b522bad34cfcaa19ab9e79f0b975d16ae02005e8d9d |
File details
Details for the file cyclonedds_nightly-2022.11.4-cp37-cp37m-musllinux_1_1_x86_64.whl
.
File metadata
- Download URL: cyclonedds_nightly-2022.11.4-cp37-cp37m-musllinux_1_1_x86_64.whl
- Upload date:
- Size: 6.6 MB
- Tags: CPython 3.7m, musllinux: musl 1.1+ x86-64
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.1 CPython/3.9.15
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | e756b80992b97e6e65b4aeaca08846a0dec0253ce2a035f926af9b8160f64f47 |
|
MD5 | ac38eb8a6e73c9a8f0112bb7ba471083 |
|
BLAKE2b-256 | 8b8aa4db3590b9508ec4b47bc8402f41b0938052e3e5b05f30465bb3996b5e4d |
File details
Details for the file cyclonedds_nightly-2022.11.4-cp37-cp37m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
.
File metadata
- Download URL: cyclonedds_nightly-2022.11.4-cp37-cp37m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
- Upload date:
- Size: 6.6 MB
- Tags: CPython 3.7m, manylinux: glibc 2.17+ x86-64
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.1 CPython/3.9.15
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 1360e31143d60173f3eadd5110c923ea9d1297c5b799b7120ba7cef002fe5eda |
|
MD5 | 588730446fe98bba48f2c711d73534fe |
|
BLAKE2b-256 | 13e255540bba3fc0de56262951e83ac0b48ff265c273bdafe9705ba020bb1384 |
File details
Details for the file cyclonedds_nightly-2022.11.4-cp37-cp37m-macosx_10_9_x86_64.whl
.
File metadata
- Download URL: cyclonedds_nightly-2022.11.4-cp37-cp37m-macosx_10_9_x86_64.whl
- Upload date:
- Size: 856.3 kB
- Tags: CPython 3.7m, macOS 10.9+ x86-64
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.1 CPython/3.9.15
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | c2b5fdbfd18b675cdb10bc8b0033422a48f567a3d791dd6f349a25b6e41902a8 |
|
MD5 | f6a705825fb5348c2fab5f2dde05128c |
|
BLAKE2b-256 | 1f631f54c54654c3ff76226bbae5e3cc38c8d864eb8500e8de8b8afe31ec169d |