Open reinzor opened 3 days ago
Dumping params don't work when there are no defaults set for a given parameter (i.e. set as PARAMETER_TYPE_DOUBLE
rather than given a default of 1.0
or a real value). I think this is just an instantiation of that and isn't a bug in R_L but a bug in the CLI tool itself that it cannot handle unset but declared variables. I've run into this kind of thing before in Nav2.
Thanks for the clarification @SteveMacenski . Though I am not sure whether the problem is in the CLI. Since getting individual parameters works but getting the full list doesn't (that is was ros2 param dump
does). So might even be in the client library layer.
Individual parameters would work, if you're not querying parameters that have no default value set. I'm guessing that the EKF node has at least one such parameter so it fails and then returns nothing. I've seen that happen before with dynamic parameter updates
ros2 param get
for all individual parameters:
base_link_frame: String value is: base_link
base_link_frame_output: String value is: base_link
control_timeout: Double value is: 0.0
debug: Boolean value is: False
diagnostic_updater.period: Double value is: 1.0
diagnostic_updater.use_fqn: Boolean value is: False
disabled_at_startup: Boolean value is: False
dynamic_process_noise_covariance: Boolean value is: False
frequency: Double value is: 30.0
gravitational_acceleration: Double value is: 9.80665
history_length: Double value is: 0.0
map_frame: String value is: map
odom_frame: String value is: odom
permit_corrected_publication: Boolean value is: False
predict_to_current_time: Boolean value is: False
print_diagnostics: Boolean value is: False
publish_acceleration: Boolean value is: False
publish_tf: Boolean value is: True
qos_overrides./odometry/filtered.publisher.depth: Integer value is: 10
qos_overrides./odometry/filtered.publisher.history: String value is: keep_last
qos_overrides./odometry/filtered.publisher.reliability: String value is: reliable
qos_overrides./parameter_events.publisher.depth: Integer value is: 1000
qos_overrides./parameter_events.publisher.durability: String value is: volatile
qos_overrides./parameter_events.publisher.history: String value is: keep_last
qos_overrides./parameter_events.publisher.reliability: String value is: reliable
qos_overrides./tf.publisher.depth: Integer value is: 100
qos_overrides./tf.publisher.durability: String value is: volatile
qos_overrides./tf.publisher.history: String value is: keep_last
qos_overrides./tf.publisher.reliability: String value is: reliable
reset_on_time_jump: Boolean value is: False
sensor_timeout: Double value is: 0.03333333333333333
smooth_lagged_data: Boolean value is: False
start_type_description_service: Boolean value is: True
transform_time_offset: Double value is: 0.0
transform_timeout: Double value is: 0.0
two_d_mode: Boolean value is: False
use_control: Boolean value is: False
use_sim_time: Boolean value is: False
world_frame: String value is: odom
imu0: Parameter not set
initial_estimate_covariance: Parameter not set
initial_state: Parameter not set
odom0: Parameter not set
pose0: Parameter not set
process_noise_covariance: Parameter not set
tf_prefix: Parameter not set
twist0: Parameter not set
So when I query all parameters that have values set:
ros2 service call /ekf_filter_node/get_parameters rcl_interfaces/srv/GetParameters 'names: ["base_link_frame", "base_link_frame_output", "control_timeout", "debug", "diagnostic_updater.period", "diagnostic_updater.use_fqn", "disabled_at_startup", "dynamic_process_noise_covariance", "frequency", "gravitational_acceleration", "history_length", "map_frame", "odom_frame", "permit_corrected_publication", "predict_to_current_time", "print_diagnostics", "publish_acceleration", "publish_tf", "qos_overrides./odometry/filtered.publisher.depth", "qos_overrides./odometry/filtered.publisher.history", "qos_overrides./odometry/filtered.publisher.reliability", "qos_overrides./parameter_events.publisher.depth", "qos_overrides./parameter_events.publisher.durability", "qos_overrides./parameter_events.publisher.history", "qos_overrides./parameter_events.publisher.reliability", "qos_overrides./tf.publisher.depth", "qos_overrides./tf.publisher.durability", "qos_overrides./tf.publisher.history", "qos_overrides./tf.publisher.reliability", "reset_on_time_jump", "sensor_timeout", "smooth_lagged_data", "start_type_description_service", "transform_time_offset", "transform_timeout", "two_d_mode", "use_control", "use_sim_time", "world_frame"]'
This will return a proper result.
However, when I add odom0
to the list (parameter that was not set) it will give me an empty response.
Not sure whether this is desired behavior. In any case, ros2 param dump
should still work in my opinion if parameters exist that have no value set. There is also no way of retrieving this information using another interface.
Describe the bug
ros2 param dump
is not dumping parameters for the robot localization nodes.To Reproduce Steps to reproduce the behavior:
ros2 run robot_localization ekf_node
ros2 param dump /ekf_filter_node
(using https://github.com/ros2/ros2cli/pull/933)Expected behavior
Should dump the parameters of the node.
Screenshots If applicable, add screenshots to help explain your problem.
Desktop (please complete the following information):
robot_localization
Package Version: 3.8.0Additional context
ros2 param list /ekf_filter_node
works:Single value getting works:
ros2 param get /ekf_filter_node base_link_frame
:Related to https://github.com/ros2/ros2cli/issues/930