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

Revision history [back]

click to hide/show revision 1
initial version

This is most likely your problem:

-- Found PythonInterp: /usr/bin/python3 (found suitable version "3.6.8", minimum required is "2") 
-- Using PYTHON_EXECUTABLE: /usr/bin/python3
...
-- Found PythonInterp: /usr/bin/python3 (found version "3.6.8")

Note how it says: Python 3 is found and used.

The Debian packages provided by the ROS buildfarm for Melodic are only installed for the default system provided Python interpreter. On Ubuntu Bionic (which you are most likely running, seeing as you tagged with melodic) that would still be Python 2.

As the Python 3 interpreter is found instead, none of the required Python packages are installed for it and this results in the error you show.

You'll either have to install catkin_pkg (and a few others) for the Python 3 interpreter (using the pip3 command shown by @Abhishekpg), or make sure Catkin uses the Python 2 interpreter.

My recommendation would be the latter, as the rest of Melodic will also have been built against Python 2. Not Python 3.

The next release of ROS 1 (Noetic) will support Python 3.

This is most likely your problem:

-- Found PythonInterp: /usr/bin/python3 (found suitable version "3.6.8", minimum required is "2") 
-- Using PYTHON_EXECUTABLE: /usr/bin/python3
...
-- Found PythonInterp: /usr/bin/python3 (found version "3.6.8")

Note how it says: Python 3 is found and used.

The Debian packages provided by the ROS buildfarm for Melodic are only installed for the default system provided Python interpreter. On Ubuntu Bionic (which you are most likely running, seeing as you tagged with melodic) that would still be Python 2.

As the Python 3 interpreter is found instead, none of the required Python packages are installed for it and this results in the error you show.

You'll either have to install catkin_pkg (and a few others) for the Python 3 interpreter (using the pip3 command shown by @Abhishekpg), @Abhishekpg ), or make sure Catkin uses the Python 2 interpreter.

My recommendation would be the latter, as the rest of Melodic will also have been built against Python 2. Not Python 3.

The next release of ROS 1 (Noetic) will support Python 3.