ROS-Comm catkin_make error
I was working on entirely a different problem of trying to publish into cmd_vel
from move_base and a custom node of mine. Basically, move_base issues twist messages to drive my robot from one pose to another. And, I was attempting to issue another set of twist messages to get my robot to follow a wall to the destination. My intention was to do this by issuing twists with just twist.angular.z = 0.5
values until to robot was a set distance from the wall.
So, these two nodes should have been publishing to cmd_vel and moving the robot along.
BUT, what i found was that my node seemed to premept move_base. The robot would not respond to move_base unless I stopped my node.
SO, I decided to experiment with the mux package and I cloned it into my catkin_ws/src directory. However, when I tried launching my launch file, I got the following error:
.
.
process[master]: started with pid [7849]
Traceback (most recent call last):
File "/home/sisko/catkin_ws/devel/bin/rosmaster", line 15, in <module>
exec(compile(fh.read(), python_script, 'exec'), context)
File "/home/sisko/catkin_ws/src/ros_comm/tools/rosmaster/scripts/rosmaster", line 35, in <module>
rosmaster.rosmaster_main()
File "/home/sisko/catkin_ws/src/ros_comm/tools/rosmaster/src/rosmaster/main.py", line 84, in rosmaster_main
configure_logging()
File "/home/sisko/catkin_ws/src/ros_comm/tools/rosmaster/src/rosmaster/main.py", line 58, in configure_logging
_log_filename = rosgraph.roslogging.configure_logging('rosmaster', logging.DEBUG, filename=filename)
File "/home/sisko/catkin_ws/src/ros_comm/tools/rosgraph/src/rosgraph/roslogging.py", line 192, in configure_logging
logging.config.fileConfig(config_file, disable_existing_loggers=False)
File "/usr/lib/python2.7/logging/config.py", line 85, in fileConfig
handlers = _install_handlers(cp, formatters)
File "/usr/lib/python2.7/logging/config.py", line 163, in _install_handlers
h = klass(*args)
File "/home/sisko/catkin_ws/src/ros_comm/tools/rosgraph/src/rosgraph/roslogging.py", line 237, in __init__
from rospy.rostime import get_time, is_wallclock
File "/home/sisko/catkin_ws/devel/lib/python2.7/dist-packages/rospy/__init__.py", line 34, in <module>
exec(__fh.read())
File "<string>", line 49, in <module>
File "/home/sisko/catkin_ws/src/ros_comm/clients/rospy/src/rospy/client.py", line 60, in <module>
import rospy.impl.init
File "/home/sisko/catkin_ws/src/ros_comm/clients/rospy/src/rospy/impl/init.py", line 54, in <module>
from .tcpros import init_tcpros
File "/home/sisko/catkin_ws/src/ros_comm/clients/rospy/src/rospy/impl/tcpros.py", line 45, in <module>
import rospy.impl.tcpros_service
File "/home/sisko/catkin_ws/src/ros_comm/clients/rospy/src/rospy/impl/tcpros_service.py", line 54, in <module>
from rospy.impl.tcpros_base import TCPROSTransport, TCPROSTransportProtocol, \
File "/home/sisko/catkin_ws/src/ros_comm/clients/rospy/src/rospy/impl/tcpros_base.py", line 160
(e_errno, msg, *_) = e.args
^
SyntaxError: invalid syntax
================================================================================REQUIRED process [master] has died!
process has died [pid 7849, exit code 1, cmd rosmaster --core -p 11311 -w 3 __log:=/home/sisko/.ros/log/9f569ecc-a37c-11eb-b1b2-70188b82a32f/master.log].
log file: /home/sisko/.ros/log/9f569ecc-a37c-11eb-b1b2-70188b82a32f/master*.log
Initiating shutdown!
================================================================================
[master] killing on exit
RLException: ERROR: could not contact master ...
why?
Why not simply
sudo apt install ros-melodic-topic-tools
?Building packages from source should be your absolute last resort.
If you're not used to doing it, it can lead to all sorts of problems. One of which you've encountered.
Thanks @gvdhoom: I tried that and it said everything is uptodate :
apt
will not solve your current problem.My question was why did you "clone[d] it into [your] catkin_ws/src directory" when you could have just
apt
installed it?The default way to install ROS packages on Debian/Ubuntu should be to use
apt
, not build them from source.The
apt
output you show actually tells us you already hadtopic_tools
installed. There was no need to build it from source.