Ask Your Question
0

Catkin build error

asked 2020-08-06 10:40:52 -0600

fabriceN gravatar image

Dear All, I am running Ros Kinetic/Ubuntu 16.04 I added a new package in the src directory, did catkin clean and when I wanted to do catkin build I got the following error:

> ros@ros:~/catkin_ws2$ source
> devel/setup.bash 
> ros@ros:~/catkin_ws2$ catkin build
---------------------------------------------------------
Profile:                     default
Extending:             [env] /opt/ros/kinetic
Workspace:                   /home/ros/catkin_ws2
---------------------------------------------------------
Source Space:       [exists] /home/ros/catkin_ws2/src
Log Space:          [exists] /home/ros/catkin_ws2/logs
Build Space:        [exists] /home/ros/catkin_ws2/build
Devel Space:        [exists] /home/ros/catkin_ws2/devel
Install Space:      [unused] /home/ros/catkin_ws2/install
DESTDIR:            [unused] None
---------------------------------------------------------
Devel Space Layout:          linked
Install Space Layout:        None
---------------------------------------------------------
Additional CMake Args:       None
Additional Make Args:        None
Additional catkin Make Args: None
Internal Make Job Server:    True
Cache Job Environments:      False
---------------------------------------------------------
Whitelisted Packages:        None
Blacklisted Packages:        None
---------------------------------------------------------
Workspace configuration appears valid.
---------------------------------------------------------
Traceback (most recent call last):
  File "/usr/bin/catkin", line 9, in <module>
    load_entry_point('catkin-tools==0.4.4', 'console_scripts', 'catkin')()
  File "/usr/lib/python2.7/dist-packages/catkin_tools/commands/catkin.py", line 267, in main
    catkin_main(sysargs)
File "/usr/lib/python2.7/dist-packages/catkin_tools/commands/catkin.py", line 262, in catkin_main
    sys.exit(args.main(args) or 0)
  File "/usr/lib/python2.7/dist-packages/catkin_tools/verbs/catkin_build/cli.py", line 420, in main
    summarize_build=opts.summarize  # Can be True, False, or None
  File "/usr/lib/python2.7/dist-packages/catkin_tools/verbs/catkin_build/build.py", line 283, in build_isolated_workspace
    workspace_packages = find_packages(context.source_space_abs, exclude_subspaces=True, warnings=[])
  File "/usr/lib/python2.7/dist-packages/catkin_pkg/packages.py", line 86, in find_packages
    packages = find_packages_allowing_duplicates(basepath, exclude_paths=exclude_paths, exclude_subspaces=exclude_subspaces, warnings=warnings)
  File "/usr/lib/python2.7/dist-packages/catkin_pkg/packages.py", line 146, in find_packages_allowing_duplicates xml, filename=filename, warnings=warnings)
  File "/usr/lib/python2.7/dist-packages/catkin_pkg/package.py", line 444,  in parse_package_string raise InvalidPackage('The manifest contains invalid XML:\n%s' % ex)
catkin_pkg.package.InvalidPackage: The manifest contains invalid XML:  no element found: line 1, column 0

I checked that I did not have any .catkin_tools directory on root because I had this error before bacause of that but nothing. Can you please tell me how to handle this error? What I missed? Thank you very much for your support

edit retag flag offensive close merge delete

1 Answer

Sort by ยป oldest newest most voted
0

answered 2020-08-09 12:15:07 -0600

Tahir M. gravatar image

updated 2020-08-09 12:15:43 -0600

Your package's package.xml seems to have some error in its first line which probably should be something like <?xml version="1.0"?>. Have a look at the error message:

raise InvalidPackage('The manifest contains invalid XML:\n%s' % ex)
catkin_pkg.package.InvalidPackage: The manifest contains invalid XML:  no element found: line 1, column 0

I will suggest just to edit package.xml or create a new package because it is created automatically by the command catkin_create_pkg

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

1 follower

Stats

Asked: 2020-08-06 10:40:52 -0600

Seen: 275 times

Last updated: Aug 09 '20