microRTPS: templates: only decode ros2_distro when possible and nedeed

This commit is contained in:
TSC21
2019-10-20 16:08:32 +01:00
committed by Nuno Marques
parent 981f8d5d90
commit 2930b55732
5 changed files with 21 additions and 5 deletions
+4 -1
View File
@@ -21,7 +21,10 @@ send_topics = [(alias[idx] if alias[idx] else s.short_name) for idx, s in enumer
recv_topics = [(alias[idx] if alias[idx] else s.short_name) for idx, s in enumerate(spec) if scope[idx] == MsgScope.RECEIVE]
package = package[0]
fastrtpsgen_version = fastrtpsgen_version[0]
ros2_distro = ros2_distro[0].decode("utf-8")
try:
ros2_distro = ros2_distro[0].decode("utf-8")
except AttributeError:
ros2_distro = ros2_distro[0]
}@
/****************************************************************************
*