ROS Resources: Documentation | Support | Discussion Forum | Index | Service Status | ros @ Robotics Stack Exchange
Ask Your Question

Revision history [back]

click to hide/show revision 1
initial version

Well, almost a decade later, I also stumbled upon this. I tracked it down to time itself: wait_for_server () returns false immediately, when time is not yet initialized. I.e. rospy.get_time() returns 0. This fixes it (almost) without magic long sleep times:

while rospy.get_time() <= 0:
    rospy.sleep(0.01)

Its just a workaround, not a real fix. But I don't dare to file a PR and mess around with time itself. It miht have something todo with simulated time, i.e. /use_sim_time and a clock server.