What to do if ROS_PACKAGE_PATH is showing up blank?
When I try to run "roscore", I get an error saying:
Invalid <param> tag: Cannot load command parameter [rosversion]: command [rosversion roslaunch] returned with code [1].
Param xml is <param command="rosversion roslaunch" name="rosversion"/>
When I try the command: rosversion roslaunch
, I get cannot locate [roslaunch]
.
I think the issue is that my ROS_PACKAGE_PATH
is empty. When I type echo $ROS_PACKAGE_PATH
it shows up empty. I've tried including it in my .bashrc
file (adding export ROS_PACKAGE_PATH=/opt/ros/kinetic/share
to my bashrc
file) but this doesn't work either. When I manually type export ROS_PACKAGE_PATH=/opt/ros/kinetic/share
, I am then able to start roscore
. However, when I open up a new terminal I get the same original error.
You shouldn't need to change your
ROS_PACKAGE_PATH
manually.Just making sure: you run
source /opt/ros/kinetic/setup.bash
in each terminal that you open, or you have that line added to your.bashrc
. Correct?If not: that would be most likely the cause of your problems.
To to be clear. have you re-run your
.bashrc
after modifying it, if not your changes will have no effect. You can so this either by opening a new terminal window or using the commandsource ~/.bashrc
All true, but manually modifying or setting
ROS_PACKAGE_PATH
is only needed in (very) rare circumstances.@gvdhoorn: Yes, I have that line in my bashrc. And yes, I re-ran my bashrc after modifying it so that’s not the issue. Any other ideas what the issue might be?
Please start by telling us much more than you do now. How did you install ROS (link to any tutorials/instructions used)? What is the output of
lsb_release -a
(assuming you are on a Debian-like OS)? And the output ofuname -a
?you cannot "run" your
.bashrc
. You have tosource
it. Or open a new terminal.