Robotics StackExchange | Archived questions

rosdep fails while installing ros2 (crystal)in ubuntu xenial 16.04

It seems like python packages are missing .

root@dcrt-lnx-2:/home/Naren/ros2_ws# rosdep install --from-paths src --ignore-src --rosdistro crystal -y --skip-keys "console_bridge fastcdr fastrtps libopensplice67 libopensplice69 python3-lark-parser rti-connext-dds-5.3.1 urdfdom_headers"
ERROR: the following packages/stacks could not have their rosdep keys resolved
to system dependencies:
test_cli_remapping: No defi**nition of [python_cmake_module] for OS version [xen**ial]
rosidl_default_runtime: No definition of [rosidl_generator_py] for OS version [xenial]
test_cli: No definition of [python_cmake_module] for OS version [xenial]
rclpy: No definition of [rosidl_generator_py] for OS version [xenial]
test_communication: No definition of [python_cmake_module] for OS version [xenias

Asked by narendarselva on 2019-05-27 05:53:04 UTC

Comments

How did you setup your workspace? Which instructions did you follow? Did you make sure to checkout the crystal versions of everything you cloned?

Asked by gvdhoorn on 2019-05-27 06:06:27 UTC

Answers

I had a similar issue when installing ROS2 from source alongside ROS1 kinetic. It looks like its due to rosdep using a wrong python version. You will need to set python3 by replacing #! /usr/bin/python with #! /usr/bin/python3 in /usr/bin/rosdep:

sudo nano /usr/bin/rosdep

Asked by pavel92 on 2019-05-27 06:27:14 UTC

Comments

Are you sure about this? The error message essentially tells us that rosdep is unable to find a package named python_cmake_module either in the workspace or in the rosdep database. The pkgs that OP seems to be missing are all part of ros2/rosidl_python, so they should not be in the rosdep database, but in his workspace. It could be an incorrect set of packages was cloned.

Do you have a rationale for how changing the Python interpreter would influence this?

Asked by gvdhoorn on 2019-05-27 06:32:29 UTC

I think you are right since my problem was that rosdep was not resolving keys for some ROS1 packages that it should not have found for ROS2. In the OP's case it is probably an incorrect set of packages as you suggested.

Asked by pavel92 on 2019-05-27 07:11:59 UTC