eclipse-iceoryx / iceoryx2

Eclipse iceoryx2™ - true zero-copy inter-process-communication in pure Rust
https://iceoryx.io
Apache License 2.0
1.03k stars 40 forks source link

Python Bindings #419

Open orecham opened 1 month ago

orecham commented 1 month ago

Brief feature description

Enable communication using iceoryx2 in Python applications.

Detailed information

A couple of options have been briefly investigated:

  1. PyO3
    1. Allows for annotating Rust functions and structs to be made available via a Python module
    2. Good overview on the topic: https://www.youtube.com/watch?v=lyG6AKzu4ew
  2. Extending using C/C++ Bindings
    1. Allows for more control over the implementation
    2. However, requires more boilerplate
    3. It is not obvious if the extra effort warrants the benefit

The PyO3 option seems more maintainable and less effort to me.

Other considerations:

  1. Loose coupling to iceoryx2 internals
    1. The implementation should not modify iceoryx2 API or its internals to work
      1. i.e. Do not directly annotate the API or its internal structs and functions, prefer to make new ones mirroring the public API for annotation