Ask Your Question

Unable to use xml formatted launch files with ROS2 eloquent

asked 2020-04-11 16:44:40 -0600

mequi gravatar image

updated 2020-04-12 04:37:46 -0600

gvdhoorn gravatar image

I am trying to get a launch file in the xml format to launch using ros2 launch launch_files launch_file.xml however when I do so I receive the error [ERROR] [launch]: Caught exception in launch (see debug for traceback): The launch file may have a syntax error, or its format is unknown. I have modeled the launch file off of the ones found in the demo_examples_cpp package, using the exact same code as the talker.listener.launch.xml example. I have checked to make sure the file ended up in the share installation folder with my files. The files work fine. I have also tried passing in the entire path to the ros2 launch command without luck. Any guidance toward getting the XML launch files to work would be greatly appreciated.

edit retag flag offensive close merge delete


@mequi: please always use permalinks when linking to artefacts on Github/Bitbucket/etc. Otherwise we run the risk of your links going stale after some time, reducing the value of your question (and any potential answer).

I've replaced the link to talker.listener.launch.xml with a permalink, but please keep it mind next time.

gvdhoorn gravatar image gvdhoorn  ( 2020-04-12 04:38:24 -0600 )edit

Uppp ! I get the same problem, I don't suceed to use xml launch file with ros2 eloquent ....

Bastien Taillandier gravatar image Bastien Taillandier  ( 2020-04-22 09:49:18 -0600 )edit

1 Answer

Sort by ยป oldest newest most voted

answered 2020-05-03 04:17:16 -0600

Thodoris Tyrovouzis gravatar image

updated 2020-10-29 05:02:25 -0600

I had the same exact problem. It seems that no package in the ros2 variants depends on launch_xml or launch_yaml (ros2launch, the only launch related dependency, does not for some reason) so they are not installed with the debian packages. You have to install it manually

sudo apt install ros-eloquent-launch-xml
sudo apt install ros-eloquent-launch-yaml

This worked for me

edit: They fixed it in the github repo, so you will no longer need to separately need to install extra packages in the next ROS2 version or next eloquent patch.

edit2: As of 29 October 2020, this was fixed in foxy, but you still need to do the above for eloquent

edit flag offensive delete link more

Your Answer

Please start posting anonymously - your entry will be published after you log in or create a new account.

Add Answer

Question Tools



Asked: 2020-04-11 16:44:40 -0600

Seen: 700 times

Last updated: Oct 29 '20