Tutorial listener-talker python

asked 2021-12-10 09:11:09 -0600

v.leto gravatar image

Hi! I need to use a python library (matplotlib), so even if I don't know pythton, I am trying to run two simple nodes in this tutorial.

link text

anyway this error apppears:

CMake Error at /opt/ros/melodic/share/catkin/cmake/catkin_install_python.cmake:20 (message):
  catkin_install_python() called without required DESTINATION argument.
Call Stack (most recent call first):![image description](/upfiles/16391486987062546.png)
  beginner_tutorials/CMakeLists.txt:19 (catkin_install_python)

image description

edit retag flag offensive close merge delete

Comments

Can you copy paste the command that you are using that is causing the error pls?

osilva gravatar image osilva  ( 2021-12-10 09:24:04 -0600 )edit

@v.leto Please do not use images of text output. Instead, you should copy/paste the text and format it with the 101010 button.

Mike Scheutzow gravatar image Mike Scheutzow  ( 2021-12-10 10:48:04 -0600 )edit

I have found the mistake.

catkin_install_python(PROGRAMS scripts/talker.py scripts/listener.py
  DESTINATION ${CATKIN_PACKAGE_BIN_DESTINATION}
)

must be pasted after

catkin_package(
#  INCLUDE_DIRS include
#  LIBRARIES beginner_tutorials
#  CATKIN_DEPENDS roscpp rospy std_msgs
#  DEPENDS system_lib
)

Thank you anyway!

v.leto gravatar image v.leto  ( 2021-12-10 11:19:59 -0600 )edit