Skip to main content

Eclipse Cyclone DDS Python binding

Project description

License License Website PyPI - Python Version PyPI Community

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

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 --help

cyclonedds ls

cyclonedds ls --help

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 ls --suppress-progress-bar --force-color-mode

cyclonedds ps

cyclonedds ps --help

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 ps --suppress-progress-bar --force-color-mode

cyclonedds typeof

cyclonedds typeof --help

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 typeof Vehicle --suppress-progress-bar --force-color-mode

cyclonedds subscribe

cyclonedds subscribe --help

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:

timeout -s INT 10s cyclonedds subscribe Vehicle --suppress-progress-bar --force-color-mode

cyclonedds performance

cyclonedds performance --help

The cyclonedds subcommand is a nicer frontend to ddsperf with four modes: publish, subscribe, ping and pong. The below performance run example is the subscribe mode rendered with cyclonedds performance publish running in the background.

cyclonedds performance --duration 21s --render-output-once-on-exit --force-color-mode subscribe --triggering-mode waitset

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.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

cyclonedds-0.10.2.tar.gz (156.8 kB view details)

Uploaded Source

Built Distributions

If you're not sure about the file name format, learn more about wheel file names.

cyclonedds-0.10.2-cp310-cp310-win_amd64.whl (2.3 MB view details)

Uploaded CPython 3.10Windows x86-64

cyclonedds-0.10.2-cp310-cp310-musllinux_1_1_x86_64.whl (6.6 MB view details)

Uploaded CPython 3.10musllinux: musl 1.1+ x86-64

cyclonedds-0.10.2-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (6.6 MB view details)

Uploaded CPython 3.10manylinux: glibc 2.17+ x86-64

cyclonedds-0.10.2-cp310-cp310-macosx_11_0_arm64.whl (797.6 kB view details)

Uploaded CPython 3.10macOS 11.0+ ARM64

cyclonedds-0.10.2-cp310-cp310-macosx_10_9_x86_64.whl (862.5 kB view details)

Uploaded CPython 3.10macOS 10.9+ x86-64

cyclonedds-0.10.2-cp39-cp39-win_amd64.whl (2.3 MB view details)

Uploaded CPython 3.9Windows x86-64

cyclonedds-0.10.2-cp39-cp39-musllinux_1_1_x86_64.whl (6.6 MB view details)

Uploaded CPython 3.9musllinux: musl 1.1+ x86-64

cyclonedds-0.10.2-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (6.6 MB view details)

Uploaded CPython 3.9manylinux: glibc 2.17+ x86-64

cyclonedds-0.10.2-cp39-cp39-macosx_11_0_arm64.whl (797.6 kB view details)

Uploaded CPython 3.9macOS 11.0+ ARM64

cyclonedds-0.10.2-cp39-cp39-macosx_10_9_x86_64.whl (862.5 kB view details)

Uploaded CPython 3.9macOS 10.9+ x86-64

cyclonedds-0.10.2-cp38-cp38-win_amd64.whl (2.3 MB view details)

Uploaded CPython 3.8Windows x86-64

cyclonedds-0.10.2-cp38-cp38-musllinux_1_1_x86_64.whl (6.6 MB view details)

Uploaded CPython 3.8musllinux: musl 1.1+ x86-64

cyclonedds-0.10.2-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (6.6 MB view details)

Uploaded CPython 3.8manylinux: glibc 2.17+ x86-64

cyclonedds-0.10.2-cp38-cp38-macosx_11_0_arm64.whl (797.6 kB view details)

Uploaded CPython 3.8macOS 11.0+ ARM64

cyclonedds-0.10.2-cp38-cp38-macosx_10_9_x86_64.whl (862.5 kB view details)

Uploaded CPython 3.8macOS 10.9+ x86-64

cyclonedds-0.10.2-cp37-cp37m-win_amd64.whl (2.3 MB view details)

Uploaded CPython 3.7mWindows x86-64

cyclonedds-0.10.2-cp37-cp37m-musllinux_1_1_x86_64.whl (6.6 MB view details)

Uploaded CPython 3.7mmusllinux: musl 1.1+ x86-64

cyclonedds-0.10.2-cp37-cp37m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (6.6 MB view details)

Uploaded CPython 3.7mmanylinux: glibc 2.17+ x86-64

cyclonedds-0.10.2-cp37-cp37m-macosx_10_9_x86_64.whl (862.4 kB view details)

Uploaded CPython 3.7mmacOS 10.9+ x86-64

File details

Details for the file cyclonedds-0.10.2.tar.gz.

File metadata

  • Download URL: cyclonedds-0.10.2.tar.gz
  • Upload date:
  • Size: 156.8 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.1 CPython/3.9.13

File hashes

Hashes for cyclonedds-0.10.2.tar.gz
Algorithm Hash digest
SHA256 f834962eabbdcdf4e9cd75cf87222f3c5ef22d9cb9e7ed651d9a8710fe984a30
MD5 431de4cc7e1683944fb971c2b4e51f13
BLAKE2b-256 62884b440f5916976234838989c3214222a5abc6fd48009a992c4dc22a86c04f

See more details on using hashes here.

File details

Details for the file cyclonedds-0.10.2-cp310-cp310-win_amd64.whl.

File metadata

File hashes

Hashes for cyclonedds-0.10.2-cp310-cp310-win_amd64.whl
Algorithm Hash digest
SHA256 a5be989f69103954c6041b80e3ea1ae9973d41b1b0e437fb71b671417c450ad6
MD5 77727d29dd041f8bab294052c0aa78b0
BLAKE2b-256 f1e73bbb2d3e6eb7aa29e2edc95ea5062458a0c92dd3e87640f83feed537e555

See more details on using hashes here.

File details

Details for the file cyclonedds-0.10.2-cp310-cp310-musllinux_1_1_x86_64.whl.

File metadata

File hashes

Hashes for cyclonedds-0.10.2-cp310-cp310-musllinux_1_1_x86_64.whl
Algorithm Hash digest
SHA256 2965d180c66d2dc03d1d39de056a57007c41c6b21173fee73b808c5123a7a1c5
MD5 064b9f9241cd5fadb03ba0be44f77af3
BLAKE2b-256 bc056b4084bc94f564ec8a1b2e4b3b3634835064fefec560f57d85a173d5c68f

See more details on using hashes here.

File details

Details for the file cyclonedds-0.10.2-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl.

File metadata

File hashes

Hashes for cyclonedds-0.10.2-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Algorithm Hash digest
SHA256 1194b03377e7644c7fb7230dd19b85eb363699d179459bdc5486974ec8d0fc0e
MD5 e5770f544a66f756da30dac151d3110c
BLAKE2b-256 c1236d8b2630e0c1f24b84c414572ca16b728c69f0d81d974756b4bf0e990afe

See more details on using hashes here.

File details

Details for the file cyclonedds-0.10.2-cp310-cp310-macosx_11_0_arm64.whl.

File metadata

File hashes

Hashes for cyclonedds-0.10.2-cp310-cp310-macosx_11_0_arm64.whl
Algorithm Hash digest
SHA256 e834a6eda188a2c48aa19fa94809511dc791ed6c13bdcc20a50b50d80bfaa1f4
MD5 b4c3f1d23ccf122ba3785e2c2b2897ad
BLAKE2b-256 042bb392a8593c9d7e7f770c60900b3ea3733704ec9786de258d6013b9faad0c

See more details on using hashes here.

File details

Details for the file cyclonedds-0.10.2-cp310-cp310-macosx_10_9_x86_64.whl.

File metadata

File hashes

Hashes for cyclonedds-0.10.2-cp310-cp310-macosx_10_9_x86_64.whl
Algorithm Hash digest
SHA256 63a7e2a2b9e326939a01c86e47f47c529e066728f41faec37e6bc8d54f2f0841
MD5 95820cbd9dbac6c2a6465d50babe438d
BLAKE2b-256 169fad6b8668e5f6d7297cdca4fa42e3c57073f5a323aa7a590e2a1581289eef

See more details on using hashes here.

File details

Details for the file cyclonedds-0.10.2-cp39-cp39-win_amd64.whl.

File metadata

  • Download URL: cyclonedds-0.10.2-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.13

File hashes

Hashes for cyclonedds-0.10.2-cp39-cp39-win_amd64.whl
Algorithm Hash digest
SHA256 765c11be0b1e2500caf1011bb73c9503d295b25b7856ef57228099d5107b2e01
MD5 75b690eaf54eb87c6174e4a773e518b7
BLAKE2b-256 4a9b6a1c0e5b300bb5c55142f96656571b421ffbefc1772d44a825b39de06e0c

See more details on using hashes here.

File details

Details for the file cyclonedds-0.10.2-cp39-cp39-musllinux_1_1_x86_64.whl.

File metadata

File hashes

Hashes for cyclonedds-0.10.2-cp39-cp39-musllinux_1_1_x86_64.whl
Algorithm Hash digest
SHA256 6e1849338d3d2fa63b5c2f0a7b517afca06f9f679778807c91b92b1b2b890f52
MD5 908067ba1ea1d512a3fdbafac42707c3
BLAKE2b-256 ee9813b0b265fea47eda143e3c5f4b9420534cbfec29f976bc5696bf76156b92

See more details on using hashes here.

File details

Details for the file cyclonedds-0.10.2-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl.

File metadata

File hashes

Hashes for cyclonedds-0.10.2-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Algorithm Hash digest
SHA256 9a26b5ec87a9a8c979bd1eb3b6264299e1f5ce01a4092339b6e8bb21989c450f
MD5 e23d2e89e6c0be6f4647231e0cc9c58c
BLAKE2b-256 947f2ed23c47d8af137a21eb0aebd4353c1b1207403c6b7212a1bc9848359ee1

See more details on using hashes here.

File details

Details for the file cyclonedds-0.10.2-cp39-cp39-macosx_11_0_arm64.whl.

File metadata

File hashes

Hashes for cyclonedds-0.10.2-cp39-cp39-macosx_11_0_arm64.whl
Algorithm Hash digest
SHA256 b5aa9dd08cabb1fd79f815deb00f724b3a3b300b972d75d76f36b963422b05bb
MD5 04f90bfc1271bff1eb8babef7578026c
BLAKE2b-256 e5007cc5806f9262af62f91b7889c874c7ff1f577fd8c444f8d5138eec88787e

See more details on using hashes here.

File details

Details for the file cyclonedds-0.10.2-cp39-cp39-macosx_10_9_x86_64.whl.

File metadata

File hashes

Hashes for cyclonedds-0.10.2-cp39-cp39-macosx_10_9_x86_64.whl
Algorithm Hash digest
SHA256 1609c5182ea155eddd09e9ded87bb6392016c9ca8a153116e5a4ca062fd7972a
MD5 455ec2f671c1ebb3f1b487db768cc82e
BLAKE2b-256 a276a197eb24994e49c66d4c11261f1d9be5f5d62655d00f9664af7bcb856a44

See more details on using hashes here.

File details

Details for the file cyclonedds-0.10.2-cp38-cp38-win_amd64.whl.

File metadata

  • Download URL: cyclonedds-0.10.2-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.13

File hashes

Hashes for cyclonedds-0.10.2-cp38-cp38-win_amd64.whl
Algorithm Hash digest
SHA256 e2f8277e942df041bdc5884123b917d2a183cb14a89e2e19476f5c98373af693
MD5 34d00925a5753cd2f960c502f5428d7e
BLAKE2b-256 8901e931e2022c00fc339e60746eaad0377889db07c6bb03239347f81b8bd0a8

See more details on using hashes here.

File details

Details for the file cyclonedds-0.10.2-cp38-cp38-musllinux_1_1_x86_64.whl.

File metadata

File hashes

Hashes for cyclonedds-0.10.2-cp38-cp38-musllinux_1_1_x86_64.whl
Algorithm Hash digest
SHA256 eb993abe137b001e9fa401a7ce927e778a31b2c4a1960adb140758710d7898f4
MD5 08afde8006f2d1da4aea6391ed08a1ba
BLAKE2b-256 8089f863efb59e1c0bff6e6426c6a6537182e25b40f3b7055d3534aac9d5fea0

See more details on using hashes here.

File details

Details for the file cyclonedds-0.10.2-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl.

File metadata

File hashes

Hashes for cyclonedds-0.10.2-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Algorithm Hash digest
SHA256 f453bb8ac1e5da5c53049b9312a076c1c02a3bf6ca5ee050bd2d1d604cc18c8a
MD5 c9209ef10ef29f7992d67842b30b1729
BLAKE2b-256 ad7db4df9d6624378936ffc4727e30c1f0b58236198b1330c9f2346fc9a6f156

See more details on using hashes here.

File details

Details for the file cyclonedds-0.10.2-cp38-cp38-macosx_11_0_arm64.whl.

File metadata

File hashes

Hashes for cyclonedds-0.10.2-cp38-cp38-macosx_11_0_arm64.whl
Algorithm Hash digest
SHA256 abbf9a39b0bb91dfc321e25eec35e1262ea34bf26bffcd90e8ba486be3c8b9b6
MD5 3188f4b3e14d498e2da573c3b1c945a0
BLAKE2b-256 388dc5973a5fcadd27e9f8913fdba2b5226fe1e77072338671c586e8e6650c99

See more details on using hashes here.

File details

Details for the file cyclonedds-0.10.2-cp38-cp38-macosx_10_9_x86_64.whl.

File metadata

File hashes

Hashes for cyclonedds-0.10.2-cp38-cp38-macosx_10_9_x86_64.whl
Algorithm Hash digest
SHA256 2f8445c5c86ad0b9ca0e259fcc53ac24983be454abb4a8d311fa1bad155512d8
MD5 138bf7ff9ced931ed87505c13d96c7f7
BLAKE2b-256 455cb7e9f3b314ec364d0d72e1dcaafd9d13755552850f765a08bf51c2692d7e

See more details on using hashes here.

File details

Details for the file cyclonedds-0.10.2-cp37-cp37m-win_amd64.whl.

File metadata

  • Download URL: cyclonedds-0.10.2-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.13

File hashes

Hashes for cyclonedds-0.10.2-cp37-cp37m-win_amd64.whl
Algorithm Hash digest
SHA256 9510cd32a406197279e2605088816a0616591ae10d9a567237f1f339057b0537
MD5 9e5e506ef8481f883752b20a5510da1e
BLAKE2b-256 8c77468ffc4d84b1fb46e926c6319ca4ec741055d424772827980e10520a9284

See more details on using hashes here.

File details

Details for the file cyclonedds-0.10.2-cp37-cp37m-musllinux_1_1_x86_64.whl.

File metadata

File hashes

Hashes for cyclonedds-0.10.2-cp37-cp37m-musllinux_1_1_x86_64.whl
Algorithm Hash digest
SHA256 94d2e468687b9baa48af31d405ee8c8581c6c07791d88e8375e1ca2224b085a4
MD5 51cc58d51c26ea500b7e905ca608eb72
BLAKE2b-256 bdf1f1ebc8b29498637a32d0a81cbf7dda5897ee1952686cebf80a4a6f7c75ff

See more details on using hashes here.

File details

Details for the file cyclonedds-0.10.2-cp37-cp37m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl.

File metadata

File hashes

Hashes for cyclonedds-0.10.2-cp37-cp37m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Algorithm Hash digest
SHA256 65962c63c52b85d3db00d286588644bf7428d9d81276d979a3e9009bdcddbdec
MD5 3050fb47cb6110d7083a9eba1f18c1e2
BLAKE2b-256 f0614be9589483008bb386618ded0cbf4de0850b12397524867ffa7afe371113

See more details on using hashes here.

File details

Details for the file cyclonedds-0.10.2-cp37-cp37m-macosx_10_9_x86_64.whl.

File metadata

File hashes

Hashes for cyclonedds-0.10.2-cp37-cp37m-macosx_10_9_x86_64.whl
Algorithm Hash digest
SHA256 6c025f773ce877e3146fc7c901ad34d6fc5837637d24495e926ad85ff7dfc465
MD5 4f97a548e8bd5b9475b938b321b956b2
BLAKE2b-256 8b7e4a640a4776d2168319d06f282ecbf2b7256d18897696aadd2a61fbd27817

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page