I can not make a catkin, i have this mistake, someone know how to solve it?

asked 2019-10-06 18:27:09 -0600

alexis080 gravatar image

updated 2019-10-07 02:12:48 -0600

gvdhoorn gravatar image

Straight dump of the error message:

Base path: /home/alexis/catkin_ws
Source space: /home/alexis/catkin_ws/src
Build space: /home/alexis/catkin_ws/build
Devel space: /home/alexis/catkin_ws/devel
Install space: /home/alexis/catkin_ws/install
#### Running command: "make cmake_check_build_system" in "/home/alexis/catkin_ws/build"
-- Using CATKIN_DEVEL_PREFIX: /home/alexis/catkin_ws/devel
-- Using CMAKE_PREFIX_PATH: /opt/ros/melodic
-- This workspace overlays: /opt/ros/melodic
-- Found PythonInterp: /usr/bin/python3 (found suitable version "3.6.8", minimum required is "2") 
-- Using PYTHON_EXECUTABLE: /usr/bin/python3
-- Using Debian Python package layout
-- Using empy: /usr/bin/empy
-- Call enable_testing()
-- Using CATKIN_TEST_RESULTS_DIR: /home/alexis/catkin_ws/build/test_results
-- Found gmock sources under '/usr/src/googletest': gmock will be built
-- Found PythonInterp: /usr/bin/python3 (found version "3.6.8") 
-- Found gtest sources under '/usr/src/googletest': gtests will be built
-- Using Python nosetests: /usr/bin/nosetests-2.7
ImportError: "from catkin_pkg.package import parse_package" failed: No module named 'catkin_pkg'
Make sure that you have installed "catkin_pkg", it is up to date and on the PYTHONPATH.
CMake Error at /opt/ros/melodic/share/catkin/cmake/safe_execute_process.cmake:11 (message):
  returned error code 1
Call Stack (most recent call first):
  /opt/ros/melodic/share/catkin/cmake/catkin_package_xml.cmake:74 (safe_execute_process)
  /opt/ros/melodic/share/catkin/cmake/all.cmake:167 (_catkin_package_xml)
  /opt/ros/melodic/share/catkin/cmake/catkinConfig.cmake:20 (include)
  CMakeLists.txt:56 (find_package)

-- Configuring incomplete, errors occurred!
See also "/home/alexis/catkin_ws/build/CMakeFiles/CMakeOutput.log".
See also "/home/alexis/catkin_ws/build/CMakeFiles/CMakeError.log".
Makefile:320: recipe for target 'cmake_check_build_system' failed
make: *** [cmake_check_build_system] Error 1
Invoking "make cmake_check_build_system" failed

I tried installing catkin_pkg and it don't works

edit retag flag offensive close merge delete


make sure to update catkin package according to the first answers of this question : https://answers.ros.org/question/2947...

tl;dr : sudo apt install --reinstall python-catkin-pkg python-catkin-pkg-modules

lmathieu gravatar image lmathieu  ( 2019-10-07 04:31:54 -0600 )edit

I am having the same error during catkin_make my package in my workspace. I did try to check my python-catkin-pkg and the python-pkg-modules with :dpkg -L python-catkin-pkg-modules, which version shown is python2.7. However, the error still persist even I did reinstall it with: sudo apt install --reinstall python-catkin-pkg python-catkin-pkg-modules. Is there anything do I missed to solve this problem?

ycean711 gravatar image ycean711  ( 2019-11-24 20:15:32 -0600 )edit