luigifreda / 3dmr

3D Multi-Robot Exploration, Patrolling and Navigation.
GNU General Public License v3.0
121 stars 14 forks source link

Error occurred during “catkin build" process for exploration_ws #2

Closed Crystal-Biru closed 6 months ago

Crystal-Biru commented 6 months ago

Hello! When I run $ ./build_all.sh, a error occured when it comes to exploration_ws. The error massage is shown below:

Errors << rotors_gazebo:make /home/zbr/Projects/3dmr/exploration_ws/logs/rotors_gazebo/build.make.000.log /bin/sh: 1: python: not found make[2]: [CMakeFiles/sdf.dir/build.make:64: /home/zbr/Projects/3dmr/exploration_ws/src/rotors_simulator/rotors_gazebo/models/iris/iris.sdf] Error 127 make[1]: [CMakeFiles/Makefile2:1231: CMakeFiles/sdf.dir/all] Error 2 make[1]: *** Waiting for unfinished jobs.... CMake Warning at CMakeLists.txt:43 (project): VERSION keyword not followed by a value or was followed by a value that expanded to nothing.

CMake Warning at /usr/src/googletest/googletest/CMakeLists.txt:54 (project): VERSION keyword not followed by a value or was followed by a value that expanded to nothing.

make: *** [Makefile:141: all] Error 2 cd /home/zbr/Projects/3dmr/exploration_ws/build/rotors_gazebo; catkin build --get-env rotors_gazebo | catkin env -si /usr/bin/make --jobserver-auth=3,4; cd -

............................................................................... Failed << rotors_gazebo:make [ Exited with code 2 ] Failed <<< rotors_gazebo [ 8.4 seconds ]
Abandoned <<< rotors_simulator [ Unrelated job failed ] Abandoned <<< interface_nbvp_rotors [ Unrelated job failed ]"

(I use Ubuntu20.04, ROS noetic, and $ ./install_all.sh is completed successfully.) Can you help me know how to solve this problem?

luigifreda commented 6 months ago

I am not sure why you are getting the following error: /bin/sh: 1: python: not found

Can you try the procedure with rosdocker that I suggested here? https://github.com/luigifreda/rosdocker#3dmr

Crystal-Biru commented 6 months ago

Thank you for your response! I have resolved this issue. I found that the 'rotors_simulator' in 'exploration_ws' was an older version that required a Python environment. I updated 'rotors_simulator' to a new version compatible with Python3, and then successfully ran 'build_all.sh'. But there is another issue: when I test multi-robot exploration through PyQt GUIs (i.e., ./main.py and ./main_pioneer.py), it seems that there are some errors for UGVs in rviz, and it can not run correctly (shown in the figure). But when I run ./main_pioneer.py, it is successful. main main_pioneer

luigifreda commented 6 months ago

I changed a couple of things related to the rotors simulator. If you replace its version in 3dmr, it is expected you hit some issues.

Why don't you try to install the package python-is-python3? https://askubuntu.com/questions/1296790/python-is-python3-package-in-ubuntu-20-04-what-is-it-and-what-does-it-actually

... or test the rosdocker procedure?

Crystal-Biru commented 6 months ago

Thank you for your advice! After installing the package python-is-python3, I successfully run $ ./build_all.sh for your original code. However, it is curious that when I run ./main.py and ./main_pioneer.py, there is still some errors (shown in the following figures), while ./main_jackal.py is ok. main main_pioneer main_jackal

luigifreda commented 6 months ago

Probably, V-REP didn't install correctly. Can you try to get into your working copy folder, remove any "temp" folder, and try to launch again ./install-vrep.sh? I recently updated the install script (since google changed a bit the cookies management for google drive). If everything goes well, after that, you should be able to launch main.pyand main_pioneer.py.

Crystal-Biru commented 6 months ago

Thank you for your help! I successfully solved this problem!