roslaunch: rosparam does not override parameters in local namespace
The wikipage on rosparam states that
Similarly, load commands can override parameters previously declared.
But I found that having a rosparam
in a node
tag does not behave this way. Am I misinterpreting the wiki page or may this be a bug?
A minimal example: This works as expected:
<launch>
<node name="my_node" pkg="roscpp_tutorials" type="talker" />
<param name="my_param" value="my value" />
<rosparam>my_param: "my_overridden_value"</rosparam>
</launch>
rosparam dump
gives "[...] myparam: myoverridden_value [...]".
But:
<launch>
<node name="my_node" pkg="roscpp_tutorials" type="talker">
<param name="my_param" value="my value" />
<rosparam>my_param: "my_overridden_value"</rosparam>
</node>
</launch>
yields "[...] mynode: {myparam: my value} [...]"., whereas on might expect "mynode: {myparam: my_overridden value}".
Asked by rossie ros on 2017-05-27 05:38:48 UTC
Comments
From the doc, I also understand that the rule should be "Last value wins", which shows to be the case at the root level of the launchfile, but not within a node description. In addition to that, manually loading this param after launching the process works as expected with
rosparam load
Asked by serial on 2017-05-30 04:11:14 UTC
@serial: If this is not the case within a node description, wouldn't this be a bug then?
Asked by Timple86 on 2019-11-14 02:08:15 UTC