`colcon test` times out for unknown reason

asked 2019-10-03 14:54:17 -0600

jdlangs gravatar image

updated 2019-10-03 14:54:32 -0600

I'm trying to run package tests locally and gtest is reporting test failures due to timeout. For example:

jlangsfeld@swri-jlangsfeld-thinkpad-T560:~/Workspaces/ros2_training$ colcon test --packages-select tf2_geometry_msgs --event-handlers console_cohesion+
Starting >>> tf2_geometry_msgs
[Processing: tf2_geometry_msgs]
[Processing: tf2_geometry_msgs]
--- output: tf2_geometry_msgs
UpdateCTestConfiguration  from :/home/jlangsfeld/Workspaces/ros2_training/build/tf2_geometry_msgs/CTestConfiguration.ini
Parse Config file:/home/jlangsfeld/Workspaces/ros2_training/build/tf2_geometry_msgs/CTestConfiguration.ini
   Site: swri-jlangsfeld-thinkpad-T560
   Build name: (empty)
 Add coverage exclude regular expressions.
SetCTestConfiguration:CMakeCommand:/usr/bin/cmake
UpdateCTestConfiguration  from :/home/jlangsfeld/Workspaces/ros2_training/build/tf2_geometry_msgs/CTestConfiguration.ini
Parse Config file:/home/jlangsfeld/Workspaces/ros2_training/build/tf2_geometry_msgs/CTestConfiguration.ini
Test project /home/jlangsfeld/Workspaces/ros2_training/build/tf2_geometry_msgs
Constructing a list of tests
Done constructing a list of tests
Updating test list for fixtures
Added 0 tests to meet fixture requirements
Checking test dependency graph...
Checking test dependency graph end
test 1
    Start 1: test_tf2_geometry_msgs

1: Test command: /usr/bin/python3 "-u" "/opt/ros/dashing/share/ament_cmake_test/cmake/run_test.py" "/home/jlangsfeld/Workspaces/ros2_training/build/tf2_geometry_msgs/test_results/tf2_geometry_msgs/test_tf2_geometry_msgs.gtest.xml" "--package-name" "tf2_geometry_msgs" "--output-file" "/home/jlangsfeld/Workspaces/ros2_training/build/tf2_geometry_msgs/ament_cmake_gtest/test_tf2_geometry_msgs.txt" "--command" "/home/jlangsfeld/Workspaces/ros2_training/build/tf2_geometry_msgs/test_tf2_geometry_msgs" "--gtest_output=xml:/home/jlangsfeld/Workspaces/ros2_training/build/tf2_geometry_msgs/test_results/tf2_geometry_msgs/test_tf2_geometry_msgs.gtest.xml"
1: Test timeout computed to be: 60
1: -- run_test.py: invoking following command in '/home/jlangsfeld/Workspaces/ros2_training/src/geometry2/tf2_geometry_msgs':
1:  - /home/jlangsfeld/Workspaces/ros2_training/build/tf2_geometry_msgs/test_tf2_geometry_msgs --gtest_output=xml:/home/jlangsfeld/Workspaces/ros2_training/build/tf2_geometry_msgs/test_results/tf2_geometry_msgs/test_tf2_geometry_msgs.gtest.xml
1/1 Test #1: test_tf2_geometry_msgs ...........***Timeout  60.03 sec

0% tests passed, 1 tests failed out of 1

Label Time Summary:
gtest    =  60.03 sec*proc (1 test)

Total Test time (real) =  60.03 sec

The following tests FAILED:
          1 - test_tf2_geometry_msgs (Timeout)
Errors while running CTest
---
--- stderr: tf2_geometry_msgs
Errors while running CTest
---
Finished <<< tf2_geometry_msgs [1min 0s]        [ with test failures ]

Summary: 1 package finished [1min 0s]
  1 package had stderr output: tf2_geometry_msgs
  1 package had test failures: tf2_geometry_msgs

If I manually run the run_test.py testing command printed above or the built test executable directly it runs and finishes instantly, as expected. Why is this timeout error happening when using colcon test?

edit retag flag offensive close merge delete

Comments

Hi there! I'm facing the same problem, did you ever find the reason behind this?

Georacer gravatar image Georacer  ( 2020-11-03 08:22:48 -0600 )edit

After all my test did finish, but the linter was taking a whole lot of time to finish too. False alarm.

Georacer gravatar image Georacer  ( 2020-11-03 10:59:15 -0600 )edit