Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add a warning to action doc that it cannot be created under ament_python #4986

Open
EmmanuelMess opened this issue Feb 2, 2025 · 4 comments

Comments

@EmmanuelMess
Copy link

The https://docs.ros.org/en/jazzy/Tutorials/Intermediate/Creating-an-Action.html document should have a warning that only a C++ package can create an action. Messages and services have the same restriction AFAIK, but I haven't check if they say so. I think this is not readily apparent, and might lead to confusion as most of the docs are separated into "how to do in python" and "how to do in cpp", but actions have no such separation and only can be done in C++.

I dont know if there is an explicit recommendation to separate interfaces into their own packages, but it should probably be added to the action creation docs, if it makes sense.

@clalancette
Copy link
Contributor

The https://docs.ros.org/en/jazzy/Tutorials/Intermediate/Creating-an-Action.html document should have a warning that only a C++ package can create an action. Messages and services have the same restriction AFAIK, but I haven't check if they say so.

To be clear, it is not that it has to be a C++ package, but rather that it has to be a CMake package; the language doesn't matter. And we do indeed say that it has to be a CMake package in https://docs.ros.org/en/rolling/Tutorials/Beginner-Client-Libraries/Custom-ROS2-Interfaces.html#create-a-new-package . So I'd be in favor of adding similar language to https://docs.ros.org/en/rolling/Tutorials/Intermediate/Creating-an-Action.html

@clalancette
Copy link
Contributor

Oh, and in case it wasn't clear; we'd very much appreciate if you opened a PR adding it!

@EmmanuelMess
Copy link
Author

To be clear, it is not that it has to be a C++ package, but rather that it has to be a CMake package; the language doesn't matter.

Wait, does that mean that you can create "crossed" cmake python packages? Is that documented somewhere I can read?

Oh, and in case it wasn't clear; we'd very much appreciate if you opened a PR adding it!

I am doing a graduate thesis right now, so that consumes most of my time, but if I can find the time I will fix these things.

@clalancette
Copy link
Contributor

Wait, does that mean that you can create "crossed" cmake python packages? Is that documented somewhere I can read?

Yes, it is possible. The documentation for it is in https://docs.ros.org/en/rolling/How-To-Guides/Ament-CMake-Python-Documentation.html . That said, we don't really recommend using it much; it is better to use ament_cmake for C++ and for message/service/action packages, and ament_python for python packages.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants