From c7b938dd2948cc4bfe838643b9706d4d1464e8cd Mon Sep 17 00:00:00 2001 From: Mohamed Fazil Date: Wed, 7 Sep 2022 15:04:05 -0700 Subject: [PATCH] stretch_driver node error out if found old stretch_body --- stretch_core/nodes/stretch_driver | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/stretch_core/nodes/stretch_driver b/stretch_core/nodes/stretch_driver index 49cfa77..95f5c87 100755 --- a/stretch_core/nodes/stretch_driver +++ b/stretch_core/nodes/stretch_driver @@ -6,6 +6,7 @@ import threading from rwlock import RWLock import stretch_body.robot as rb from stretch_body.hello_utils import ThreadServiceExit +import stretch_body import tf2_ros import tf_conversions @@ -338,6 +339,10 @@ class StretchBodyNode: rospy.loginfo("{0} started".format(self.node_name)) + if int(stretch_body.__version__.split('.')[1]) < 4: + rospy.logerr("ERROR: Found old stretch_body version. Please upgrade stretch_body to 0.4.0 or above.") + rospy.signal_shutdown('Found old stretch_body version.') + self.robot = rb.Robot() self.robot.startup()