Skip to content

Commit

Permalink
Drop deprecated get_container_components_info() API. (#647)
Browse files Browse the repository at this point in the history
Signed-off-by: Michel Hidalgo <michel@ekumenlabs.com>
  • Loading branch information
hidmic authored Jun 7, 2021
1 parent 7a6f3b8 commit 6cd7a37
Showing 1 changed file with 0 additions and 28 deletions.
28 changes: 0 additions & 28 deletions ros2component/ros2component/api/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -68,34 +68,6 @@ def get_registered_component_types():
ComponentInfo = namedtuple('Component', ('uid', 'name'))


def get_container_components_info(*, node, remote_container_node_name):
"""
Get information about the components in a container.
.. deprecated:: Galactic
Use :func:`get_components_in_container()` instead.
:param node: an `rclpy.Node` instance.
:param remote_container_node_name: of the container node to inspect.
:return: a list of `ComponentInfo` instances, with the unique id and name of
each component in the container.
:throws: RuntimeError if an error occurs.
"""
import warnings
warnings.warn(
'get_container_components_info() is deprecated. '
'Use get_components_in_container() instead.'
)

ok, outcome = get_components_in_container(
node=node, remote_container_node_name=remote_container_node_name
)
if not ok:
raise RuntimeError(f'{outcome} for {remote_container_node_name}')
return outcome


def get_components_in_container(*, node, remote_container_node_name):
"""
Get information about the components in a container.
Expand Down

0 comments on commit 6cd7a37

Please sign in to comment.