Closed minggangw closed 3 years ago
@minggangw I think it would be helpful to extend the comment on Publisher#publish() to note the null terminated string requirement. If you update the doc please update the publisher.d.ts api accordingly. https://github.com/RobotWebTools/rclnodejs/blob/31efa7c28e8d20bcd6fe1311fb10e9afa7bd63a7/lib/publisher.js#L41
Also I notice the raw publisher example does not use null terminated string. https://github.com/RobotWebTools/rclnodejs/blob/31efa7c28e8d20bcd6fe1311fb10e9afa7bd63a7/example/publisher-raw-message.js#L35
The description of #771 may mislead the readers. I'd like to clarify it:
\0
recently which causes the failure. In order to pass the unit test, we have to use a null-terminated string when comparing.I think we should update the comments for the subscription instead, what do you think?
Fix #771