Rosrun tab autocompletion crashes terminal
I have been using ROS Kinetic on Ubuntu 16.04 for some time now. After doing some kernel upgrades I run into a problem when running the rosrun
command. When I hit the tab after writing rosrun
the terminal freezes and crashes after few seconds. This does not happen for roslaunch
or other ros commands. If I type the whole rosrun
command with the node that I want to run it works as expected. Has anyone encountered this problem? There was a question regarding this that proposed some fixes that unfortunately did not work for me (deleting the contents of /var/crash
and doing a clean build).
Edit:
The output of env |grep -i ros |sort
is:
CMAKE_PREFIX_PATH=/home/pavel/catkin_ws/devel:/opt/ros/kinetic
LD_LIBRARY_PATH=/home/pavel/catkin_ws/devel/lib:/opt/ros/kinetic/lib:/opt/ros/kinetic/lib/x86_64-linux-gnu
PATH=/opt/ros/kinetic/bin:/home/pavel/bin:/home/pavel/.local/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/local/games:/snap/bin
PKG_CONFIG_PATH=/home/pavel/catkin_ws/devel/lib/pkgconfig:/opt/ros/kinetic/lib/pkgconfig:/opt/ros/kinetic/lib/x86_64-linux-gnu/pkgconfig
PYTHONPATH=/home/pavel/catkin_ws/devel/lib/python2.7/dist-packages:/opt/ros/kinetic/lib/python2.7/dist-packages
ROS_DISTRO=kinetic
ROS_ETC_DIR=/opt/ros/kinetic/etc/ros
ROS_MASTER_URI=http://localhost:11311
ROS_PACKAGE_PATH=/home/pavel/catkin_ws/src/pkg1:/home/pavel/catkin_ws/src/pkg2:......../opt/ros/kinetic/share
ROS_ROOT=/opt/ros/kinetic/share/ros
ROS_VERSION=1
where the ROS_PACKAGE_PATH
contains a lot of packages, but to make it short I just put pkg1, pkg2.... in the output above.
What is the output of
env |grep -i ros |sort
?I edited the question with the output
Have you sourced your workspace ? The variable ROS_PACKAGE_PATH should be
/home/pavel/catkin_ws/src:/opt/ros/kinetic/share
Try
unset ROS_PACKAGE_PATH
, and thensource devel/setup.bash
. Is the output the same ? (only forROS_PACKAGE_PATH
)When I do a clean build
ROS_PACKAGE_PATH
gives only/opt/ros/kinetic/share
. After I source the workspace I get the same package path that was shown in the question. When i unset theROS_PACKAGE_PATH
and source the workspace the package path is the same and the crash still occursHave you modified your
.bashrc
? Moreover have you runsudo apt-get update
, thensudo apt-get upgrade
and finallysudo apt-get autoremove
?Did that but it did not help. I had this added in my .bashrc:
Can you just try to
unset ROS_PACKAGE_PATH
and thenexport ROS_PACKAGE_PATH=/home/pavel/catkin_ws/src:/opt/ros/kinetic/share
(don't source your workspace after that and try the autocompletion) just to make sure the problem isn't with this variable not correctly set.