Skip to content

Add warning that actions require ament_cmake, not ament_python #4986 #5201

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

Open
wants to merge 13 commits into
base: rolling
Choose a base branch
from
Open
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 6 additions & 0 deletions source/Tutorials/Intermediate/Creating-an-Action.rst
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,12 @@ Tasks
1 Creating an interface package
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

.. warning::
Actions can only be created in a C++ package using ``ament_cmake``. They are not supported in Python packages using ``ament_python``. This restriction also applies to messages and services, so ensure your package is configured as a C++ package before proceeding with this tutorial.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
Actions can only be created in a C++ package using ``ament_cmake``. They are not supported in Python packages using ``ament_python``. This restriction also applies to messages and services, so ensure your package is configured as a C++ package before proceeding with this tutorial.
Interfaces for Actions (along with Message and Service) can only be generated by a package which has ``ament_cmake`` as its ``build_type``.

.. note::
It is recommended to define action interfaces (as well as messages and services) in a separate package dedicated to interfaces, as shown in this tutorial. This improves modularity and makes it easier to reuse them across multiple projects.

Copy link
Member

@Yadunund Yadunund Mar 31, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I suggest to move these two statements above the warning and outside the note block (ie, standalone statements) right after the Creating an interface package header.

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

okay

.. tabs::

.. group-tab:: Linux
Expand Down