Why doesn't ROS2 warn me when my interfaces are incompatible?
I'm currently developing an application that involves a Windows machine talking with a Linux machine and more than once I've accidentally used different interface definitions for a publisher and subscriber. Surprisingly, no error or warning is given when the communication is attempted and instead I see behavior like trying to deserialize bytes that aren't there or getting garbage output because a different type is expected than the one that comes over the wire.
I believe ROS1 was quite good about checking the topic type matched on both ends with something like a checksum. Do we not have the same capability in ROS2? It would be very useful for preventing errors in multi-machine scenarios where source builds can easily get out of sync.
Asked by jdlangs on 2021-04-21 11:20:15 UTC
Comments
I don't know the answer, but I'm wondering whether ROS Answers is the best place to ask this.
Yes, it's a question about "usage" of ROS 2, but the people who are most likely to know the answer don't necessarily frequent this site.
You might want to consider creating an issue on the relevant issue tracker(s). Perhaps the
rclcpp
one? Or one of the RMWs? Or if it's all RMWs and alsorclpy
: perhaps theros2/ros2
tracker?If/when you do post somewhere else, please post a comment here with a link so we can keep things connected.
Asked by gvdhoorn on 2021-04-22 05:12:20 UTC
I've actually had good past experience getting answers to general ROS2 questions here, usually from @William. And it's not clear to me this is yet an issue or feature request as I'm sure there's some existing context that complicates things. But you may be right this won't get visibility, in which case I may consider going to Discourse instead for a more general discussion.
Asked by jdlangs on 2021-04-22 11:11:06 UTC