Conversation
Signed-off-by: Tomoya Fujita <Tomoya.Fujita@sony.com>
Signed-off-by: Tomoya Fujita <Tomoya.Fujita@sony.com>
Signed-off-by: Tomoya Fujita <Tomoya.Fujita@sony.com>
Signed-off-by: Tomoya Fujita <Tomoya.Fujita@sony.com>
Signed-off-by: Tomoya Fujita <Tomoya.Fujita@sony.com>
|
@araitaiga can you review this? |
|
Pulls: #1185 |
| parser.add_argument( | ||
| '--include-hidden-nodes', action='store_true', | ||
| help='Consider hidden nodes as well') | ||
| parser.add_argument( |
There was a problem hiding this comment.
Would it make sense to add a default timeout for lifecycle get, so that it stays consistent with other multi-node verbs?
ros2 param list and ros2 component list both use a default timeout of 5.0s, since they may query multiple nodes and a single unresponsive node could otherwise block the command indefinitely.
ros2 lifecycle get behaves similarly when the node name is omitted, but --timeout currently has no default value and therefore waits indefinitely.
How about applying a consistent policy where verbs that may query multiple nodes default to 5.0s?
| rclpy.spin_until_future_complete(node, future) | ||
| rclpy.spin_until_future_complete(node, future, timeout_sec=timeout) | ||
| if not future.done(): | ||
| raise RuntimeError( |
There was a problem hiding this comment.
Would it be possible to include the node name in timeout error messages for call_get_states (and related functions)?
In this PR, most timeout errors already include the node or service name, but the lifecycle functions (call_get_states, call_change_states) currently do not. This can be confusing for users of call_get_states, since ros2 lifecycle get may query multiple nodes in a loop, making it hard to identify which node was unresponsive when a timeout occurs.
Description
Follow up of #1170, so that we can avoid the hang-up situation described in #1159
Fixes # (issue)
Is this user-facing behavior change?
No, the additional timeout falls back to the current behavior.
Did you use Generative AI?
Yes, Claude Sonnet 4.5
Additional Information