Open Aposhian opened 1 year ago
using https://github.com/fujitatomoya/ros2_test_prover/blob/master/prover_rclcpp/src/rclcpp_2166.cpp with
testns:
node1:
ros__parameters:
param: 1.0
node2:
ros__parameters:
param: 2.0
i do not have the problem with rolling https://github.com/ros2/ros2/commit/fea3f22ebc1becc6303aebcc9f93bde5abf0f92d
### Start 2 nodes under namespace testns with loading parameter file
root@tomoyafujita:~/ros2_ws/colcon_ws# ros2 run prover_rclcpp rclcpp_2166 --ros-args --params-file test_params.yaml
[INFO] [1681970561.659209435] [testns.node1]: node1 created...
[INFO] [1681970561.661174465] [testns.node2]: node2 created...
# Check parameter list for all nodes
root@tomoyafujita:~/ros2_ws/colcon_ws# ros2 param list
/testns/node1:
param
qos_overrides./parameter_events.publisher.depth
qos_overrides./parameter_events.publisher.durability
qos_overrides./parameter_events.publisher.history
qos_overrides./parameter_events.publisher.reliability
use_sim_time
/testns/node2:
param
qos_overrides./parameter_events.publisher.depth
qos_overrides./parameter_events.publisher.durability
qos_overrides./parameter_events.publisher.history
qos_overrides./parameter_events.publisher.reliability
use_sim_time
unfortunately i am not sure which PR addressed this issue. CC: @iuhilnehc-ynos
i do not have the problem with rolling ros2/ros2@fea3f22 unfortunately i am not sure which PR addressed this issue. CC: @iuhilnehc-ynos
I am not able to reproduce the issue either in humble
or rolling
. More information is needed.
@Aposhian we are not able to reproduce the issue, can you confirm the reproducible environment?
Ok I'll try to get a repro soon
Bug report
Required Info:
Steps to reproduce issue
Try a params yaml like this:
Expected behavior
node1
to haveparam
with a value of 1.0, andnode2
to haveparam
with a value of 2.0Actual behavior
node1
has aparam
set to 1.0 andnode2
has a value ofparam
that is the default. The value from yaml is not applied.Additional information
Also reported here: https://answers.ros.org/question/394231/ros2-how-to-get-multiple-nodes-under-same-namespace-in-yaml-config-file/
Interestingly, having top level duplicate keys works, even though that is not technically valid yaml, like this: