message is published but only partially (message_details specifies several ros messages separated by '---' but only first message is published)
it seems things are actually working as they should.
According to the wiki page (emphasis mine):
-f FILE
Read message fields from YAML file. YAML syntax is equivalent to output of rostopic echo
. Messages are separated using YAML document separator ---
. To use only the first message in a file, use the --latch
option.
(this is the same info you'd get when running rostopic pub --help
btw)
Note how it mentions the latch option and how that causes rostopic pub
to only publish "the first message".
You have the -l
command line option in your args
attribute in the .launch
file you show:
<node pkg="rostopic" type="rostopic" name="arbitrary_node_name" args="pub topic_name msg_type -l -f $(find package_name)/message_details.yaml" output="screen" />
That would be the short version of --latch
.
Correction: message is published but only partially (message_details specifies several ros messages separated by '---' but only first message is published)