Contents
- I. Installation Issues
- Solutions for rosdep_init and rosdep_update Issues During ROS Installation
- II. Environment Issues
- Unable to find either executable ‘empy’ or Python module ‘em’… try installing the package ‘python3-empy’
- Could not find a package configuration file provided by “某某包” with any of the following names
- When Rviz Displays a Model, It Shows Status:Error,No transform from [link1] to [base_link]
- III. Configuration Issues
- ERROR: cannot launch node of type [robot_state_publisher/state_publisher]: Cannot locate node of type [state_publisher] in package [robot_state_publisher]. Make sure file exists in package path and permission is set to executable (chmod +x)
- joint state publisher gui Does Not Appear
I. Installation Issues
Solutions for rosdep_init and rosdep_update Issues During ROS Installation
Solution
Use the following commands in place of the two commands above
sudo apt-get install python3-pip
sudo pip3 install rosdepc
sudo rosdepc init
rosdepc update
II. Environment Issues
Unable to find either executable ‘empy’ or Python module ‘em’… try installing the package ‘python3-empy’
(1) Cause
Anaconda uses the Python3 version, but ROS uses Python2
(2) Solution 1: Do not use the conda environment
conda deactivate
(3) Solution 2: If you need to use the conda environment
Use the following commands to check your python paths
ls /usr/bin/python*
ls /usr/include/python*
In the workspace directory, set the Python path so ROS compiles with Python 3.
catkin_make -DPYTHON_EXECUTABLE=/usr/bin/python3 -DPYTHON_INCLUDE_DIR=/usr/include/python3.7m
Could not find a package configuration file provided by “某某包” with any of the following names
(1) Cause
Missing 某某包
(2) Solution
sudo apt-get install ros-noetic-某某包
When Rviz Displays a Model, It Shows Status:Error,No transform from [link1] to [base_link]
(1) Cause
Online sources list many possible causes for this issue:
- Fixed Frame is not selected correctly You should select the model’s fixed link, or set up a transform from map to the model’s fixed link.
- The Launch file does not add
robot_state_publisherandjoint_state_publisher_gui<node name="robot_state_publisher" pkg="robot_state_publisher" type="robot_state_publisher" /><node name="joint_state_publisher_gui" pkg="joint_state_publisher_gui" type="joint_state_publisher_gui" />- Not installing
unicodecauses incompatible commentssudo apt-get install unicodeand restart
(2) Actual Cause
After trying these, my case did not match any of the three above; instead, the terminal was defaulting to the anaconda3 default environment base, which is the python3 version and has some compatibility issues with ROS.
Solution: conda deactivate
Or a permanent fix: conda config --set auto_activate_base false; if you change your mind, you can restore it with conda config --set auto_activate_base true
III. Configuration Issues
ERROR: cannot launch node of type [robot_state_publisher/state_publisher]: Cannot locate node of type [state_publisher] in package [robot_state_publisher]. Make sure file exists in package path and permission is set to executable (chmod +x)
(1) Cause
This issue appears when launching a node with a launch file because the name, pkg, and type in the launch file are inconsistent.
(2) Solution
Check the launch file and make sure name, pkg, and type match, for example:
<node name="robot_state_publisher" pkg="robot_state_publisher" type="robot_state_publisher" />
joint state publisher gui Does Not Appear
(1) Problem Description
While using ROS for simulation, I wanted to use joint state publisher to control a robotic arm, but after starting the launch file there was no error message, and also no joint state publisher gui.
(2) Solution
Starting in 2020, the gui was moved out of joint state publisher and became a new package: joint state publisher gui. The previous approach of calling joint state publisher with a gui parameter is still possible, but it will not invoke the gui.
In the launch file, replace joint state publisher with joint__state__publisher_gui.

Comments