fmrico / book_ros2

552 stars 112 forks source link

Fail to install missing packages with rosdep #8

Closed carlosfloar closed 2 years ago

carlosfloar commented 2 years ago

Type of bug

Issue Description

Fail to install missing packages whit rosdep, after entering the command "rosdep install --from-paths src --ignore-src -r -y" there are problems when creating the librealsense2-dkms module, and it stays in a loop deleting and creating the librealsense2-dkms folder and reporting an error and then returning an error saying that several repositories are missing to be installed.

A) Typo/Error Description

B) Bug Description

after using rosdep these are the last lines:

Deleting module version: 1.3.19 completely from the DKMS tree.

Done. Loading new librealsense2-dkms-1.3.19 DKMS files... Building for 5.14.0-1054-oem Building initial module for 5.14.0-1054-oem ERROR: Cannot create report: [Errno 17] File exists: '/var/crash/librealsense2-dkms.0.crash' Error! Bad return status for module build on kernel: 5.14.0-1054-oem (x86_64) Consult /var/lib/dkms/librealsense2-dkms/1.3.19/build/make.log for more information. dpkg: error al procesar el paquete librealsense2-dkms (--configure): el subproceso instalado paquete librealsense2-dkms script post-installation devolvió el código de salida de error 10 Se encontraron errores al procesar: librealsense2-dkms E: Sub-process /usr/bin/dpkg returned an error code (1) executing command [sudo -H apt-get install -y ros-foxy-joint-state-publisher-gui] Leyendo lista de paquetes... Hecho Creando árbol de dependencias
Leyendo la información de estado... Hecho El paquete indicado a continuación se instaló de forma automática y ya no es necesario. libxmlb1 Utilice «sudo apt autoremove» para eliminarlo. Se instalarán los siguientes paquetes adicionales: ros-foxy-joint-state-publisher Se instalarán los siguientes paquetes NUEVOS: ros-foxy-joint-state-publisher ros-foxy-joint-state-publisher-gui 0 actualizados, 2 nuevos se instalarán, 0 para eliminar y 0 no actualizados. 1 no instalados del todo o eliminados. Se necesita descargar 27,8 kB de archivos. Se utilizarán 127 kB de espacio de disco adicional después de esta operación. Des:1 http://packages.ros.org/ros2/ubuntu focal/main amd64 ros-foxy-joint-state-publisher amd64 2.2.0-1focal.20221012.233646 [14,3 kB] Des:2 http://packages.ros.org/ros2/ubuntu focal/main amd64 ros-foxy-joint-state-publisher-gui amd64 2.2.0-1focal.20221013.004502 [13,5 kB] Descargados 27,8 kB en 0s (69,0 kB/s)
Seleccionando el paquete ros-foxy-joint-state-publisher previamente no seleccionado. (Leyendo la base de datos ... 543051 ficheros o directorios instalados actualmente.) Preparando para desempaquetar .../ros-foxy-joint-state-publisher_2.2.0-1focal.20221012.233646_amd64.deb ... Desempaquetando ros-foxy-joint-state-publisher (2.2.0-1focal.20221012.233646) ... Seleccionando el paquete ros-foxy-joint-state-publisher-gui previamente no seleccionado. Preparando para desempaquetar .../ros-foxy-joint-state-publisher-gui_2.2.0-1focal.20221013.004502_amd64.deb ... Desempaquetando ros-foxy-joint-state-publisher-gui (2.2.0-1focal.20221013.004502) ... Configurando ros-foxy-joint-state-publisher (2.2.0-1focal.20221012.233646) ... Configurando ros-foxy-joint-state-publisher-gui (2.2.0-1focal.20221013.004502) ... Configurando librealsense2-dkms (1.3.19-0ubuntu1) ... Removing old librealsense2-dkms-1.3.19 DKMS files...

Deleting module version: 1.3.19 completely from the DKMS tree.

Done. Loading new librealsense2-dkms-1.3.19 DKMS files... Building for 5.14.0-1054-oem Building initial module for 5.14.0-1054-oem ERROR: Cannot create report: [Errno 17] File exists: '/var/crash/librealsense2-dkms.0.crash' Error! Bad return status for module build on kernel: 5.14.0-1054-oem (x86_64) Consult /var/lib/dkms/librealsense2-dkms/1.3.19/build/make.log for more information. dpkg: error al procesar el paquete librealsense2-dkms (--configure): el subproceso instalado paquete librealsense2-dkms script post-installation devolvió el código de salida de error 10 Se encontraron errores al procesar: librealsense2-dkms E: Sub-process /usr/bin/dpkg returned an error code (1) ERROR: the following rosdeps failed to install apt: command [sudo -H apt-get install -y ros-foxy-gazebo-plugins] failed apt: command [sudo -H apt-get install -y ros-foxy-behaviortree-cpp-v3] failed apt: command [sudo -H apt-get install -y ros-foxy-gazebo-msgs] failed apt: command [sudo -H apt-get install -y ros-foxy-gazebo-ros] failed apt: command [sudo -H apt-get install -y ros-foxy-realtime-tools] failed apt: command [sudo -H apt-get install -y ros-foxy-gazebo-dev] failed apt: command [sudo -H apt-get install -y ros-foxy-control-msgs] failed apt: command [sudo -H apt-get install -y ros-foxy-control-toolbox] failed apt: command [sudo -H apt-get install -y ros-foxy-vision-msgs] failed apt: command [sudo -H apt-get install -y ros-foxy-joy-teleop] failed apt: command [sudo -H apt-get install -y ros-foxy-nav2-msgs] failed apt: command [sudo -H apt-get install -y ros-foxy-diagnostic-updater] failed apt: command [sudo -H apt-get install -y ros-foxy-joint-state-publisher-gui] failed

how to reproduce

Steps to reproduce the behavior:

  1. Clone the foxy-devel repository
  2. Add sources with vcstool
  3. Execute 'rosdep install --from-paths src --ignore-src -r -y' in the bookros2_ws directory
  4. See error

Desktop:

fmrico commented 2 years ago

Sometimes some packages are marked as dependencies, but they are not used, at least for building. But in this case, the missing packages should be available for installation in Foxy :thinking: Network problems? Did you do an apt-upgrade?

Did you try to build after these errors?

carlosfloar commented 2 years ago

I already uninstalled the librealsense2-dmk package and that problem is gone, now after giving colcon --symlink-install, groot produces an error: colcon build --symlink-install Starting >>> controller_manager_msgs Starting >>> ros2_control_test_assets Starting >>> launch_pal Starting >>> twist_mux Starting >>> hey5_description Starting >>> tiago_description_calibration Starting >>> pal_gazebo_worlds Starting >>> urdf_test Starting >>> pmb2_maps Starting >>> br2_tracking_msgs Starting >>> br2_basics Starting >>> br2_bt_bumpgo Starting >>> br2_bt_patrolling Starting >>> br2_fsm_bumpgo_cpp Starting >>> br2_fsm_bumpgo_py Starting >>> br2_navigation Finished <<< ros2_control_test_assets [0.81s]
Starting >>> hardware_interface Finished <<< tiago_description_calibration [0.84s] Starting >>> br2_tf2_detector Finished <<< pmb2_maps [0.90s]
Starting >>> pmb2_2dnav Finished <<< urdf_test [0.95s] Starting >>> pal_gripper_description Finished <<< hey5_description [0.99s]
Starting >>> br2_tiago Finished <<< br2_navigation [1.47s]
Starting >>> br2_vff_avoidance Finished <<< launch_pal [1.69s]
Starting >>> groot Finished <<< br2_fsm_bumpgo_py [1.74s]
Finished <<< br2_tiago [3.54s]
Finished <<< pmb2_2dnav [3.73s]
Starting >>> pmb2_navigation Finished <<< pal_gripper_description [5.23s]
Finished <<< pal_gazebo_worlds [15.4s]
Finished <<< br2_tracking_msgs [18.1s]
Starting >>> br2_tracking Finished <<< pmb2_navigation [13.8s]
Finished <<< br2_basics [19.4s]
Finished <<< br2_fsm_bumpgo_cpp [20.0s]
Finished <<< hardware_interface [23.0s]
Starting >>> controller_interface Starting >>> transmission_interface Finished <<< twist_mux [23.8s] stderr: groot
/home/carlos/bookros2_ws/src/ThirdParty/Groot/bt_editor/XML_utilities.cpp: In function ‘bool VerifyXML(QDomDocument&, const std::vector&, std::vector&)’: /home/carlos/bookros2_ws/src/ThirdParty/Groot/bt_editor/XML_utilities.cpp:203:33: error: invalid initialization of reference of type ‘const std::set<std::cxx11::basic_string >&’ from expression of type ‘std::unordered_map<std::cxx11::basic_string, BT::NodeType>’ 203 | BT::VerifyXML(xml_text, registered_nodes); // may throw | ^~~~ In file included from /home/carlos/bookros2_ws/src/ThirdParty/Groot/bt_editor/XML_utilities.cpp:6: /opt/ros/foxy/include/behaviortree_cpp_v3/xml_parsing.h:38:45: note: in passing argument 2 of ‘void BT::VerifyXML(const string&, const std::set<std::__cxx11::basic_string >&)’ 38 | const std::set &registered_nodes); | ~~~~~~~^~~~~~ make[2]: [CMakeFiles/behavior_tree_editor.dir/build.make:251: CMakeFiles/behavior_tree_editor.dir/bt_editor/XML_utilities.cpp.o] Error 1 make[2]: Se espera a que terminen otras tareas.... make[1]: [CMakeFiles/Makefile2:158: CMakeFiles/behavior_tree_editor.dir/all] Error 2 make: [Makefile:141: all] Error 2

Failed <<< groot [23.4s, exited with code 2] Aborted <<< transmission_interface [2.01s]
Aborted <<< controller_manager_msgs [25.9s]
Aborted <<< br2_tf2_detector [25.3s]
Aborted <<< controller_interface [2.53s]
Aborted <<< br2_bt_bumpgo [26.8s]
Aborted <<< br2_vff_avoidance [28.7s]
Aborted <<< br2_bt_patrolling [30.4s]
Aborted <<< br2_tracking [17.1s]

Summary: 18 packages finished [35.5s] 1 package failed: groot 8 packages aborted: br2_bt_bumpgo br2_bt_patrolling br2_tf2_detector br2_tracking br2_vff_avoidance controller_interface controller_manager_msgs transmission_interface 1 package had stderr output: groot 30 packages not processed

carlosfloar commented 2 years ago

I deleted the install and build folders, then performed a system update, updated some ROS packages and performed again the procedure described in the book with success.