-
Notifications
You must be signed in to change notification settings - Fork 170
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 'service type' verb #273
Conversation
Signed-off-by: artivis <jeremie.deray@canonical.com>
ros2service/ros2service/verb/type.py
Outdated
|
||
for (service_name, service_types) in service_names_and_types: | ||
if args.service_name == service_name: | ||
print(service_types[0]) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Why should this only print the first type? (I guess the same question applies to the previous topic PR.)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
First, can it really have several types ?? If so then this is a mistake.
I only print the first one for a formatting purpose, I could do the same with a loop I guess.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
can it really have several types ??
Yes, it can have multiple types. That is why the API returns a list of type names.
I could do the same with a loop I guess.
👍 one type per line sounds good.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Done.
Signed-off-by: artivis <jeremie.deray@canonical.com>
* Assert the client call succeeded Signed-off-by: Shane Loretz <sloretz@openrobotics.org> * Shutdown rclpy when test throws exceptions Signed-off-by: Shane Loretz <sloretz@openrobotics.org>
Add the
type
verb toservice
which return the type of a given service.E.g.
given
ros2 run demo_nodes_cpp talker