ROS Resources: Documentation | Support | Discussion Forum | Index | Service Status | ros @ Robotics Stack Exchange
Ask Your Question

XML Parsing Error: prefix not bound to a namespace

asked 2013-02-11 07:51:03 -0500

MartinW gravatar image

updated 2013-02-11 08:00:22 -0500

Hello all,

I'm getting a parsing error with my urdf when I try to run it. it says the error comes from this line <controller:gazebo_ros_time name="gazebo_ros_time" plugin="">

This is the console error upon launch:

Traceback (most recent call last):
  File "/opt/ros/fuerte/stacks/xacro/", line 35, in <module>
  File "/opt/ros/fuerte/stacks/xacro/src/", line 542, in main
    doc = parse(f)
  File "/usr/lib/python2.7/xml/dom/", line 1920, in parse
    return expatbuilder.parse(file)
  File "/usr/lib/python2.7/xml/dom/", line 928, in parse
    result = builder.parseFile(file)
  File "/usr/lib/python2.7/xml/dom/", line 207, in parseFile
    parser.Parse(buffer, 0)
xml.parsers.expat.ExpatError: unbound prefix: line 795, column 6
Invalid <param> tag: Cannot load command parameter [robot_description]: command [/opt/ros/fuerte/stacks/xacro/ '/Martin/ros_workspace/learning_urdf/H20_urdf.urdf'] returned with code [1]. 

Param xml is <param command="$(find xacro)/ '$(find learning_urdf)/H20_urdf.urdf'" name="robot_description"/>

Here is the whole code:

     <controller:gazebo_ros_time name="gazebo_ros_time" plugin="">
        <interface:audio name="dummy_gazebo_ros_time_iface_should_not_be_here"/>

      <!-- PR2_ACTARRAY -->
      <controller:gazebo_ros_controller_manager name="gazebo_ros_controller_manager" plugin="">
        <interface:audio name="gazebo_ros_controller_manager_dummy_iface" />


EDIT: This code does work when I try to launch this with the gazebo simulator but when I try to launch it with my warehouse planning launch file it gives this crash. Does it have to do with using different time? My warehouse launch file uses But the urdf file specifies this <controller:gazebo_ros_time name="gazebo_ros_time" plugin="">

Hope someone can help, thanks in advance!

Kind Regards, Martin

edit retag flag offensive close merge delete

1 Answer

Sort by ยป oldest newest most voted

answered 2013-03-14 07:36:05 -0500

This error looks similar to another URDF-parsing issue I was just researching here.

Some of the XML parsers used in ROS are more picky than others about specific URDF syntax. The other issue I linked to was resolved by adding extra xmlns:controller and xmlns:interface attributes that tell the ROS XML parsers how to interpret some of those gazebo tags. Maybe a similar fix could apply to your case.

In the other example, the <gazebo> node also needed to be wrapped in a <robot> node. I am not very familiar with gazebo, so I'm not sure if the XML snippet you provided is just a piece of a larger file, or is the entire URDF file. It certainly is missing most of the common robot-kinematics components of a "normal" URDF file.

edit flag offensive delete link more

Question Tools


Asked: 2013-02-11 07:51:03 -0500

Seen: 2,574 times

Last updated: Mar 14 '13