Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Equal md5-sums for different message definitions #50

Closed
airballking opened this issue Jun 30, 2014 · 3 comments
Closed

Equal md5-sums for different message definitions #50

airballking opened this issue Jun 30, 2014 · 3 comments
Labels

Comments

@airballking
Copy link

We came across the following effect: For certain message definitions which differ the md5-sums are equal! I created a short example here: airballking/ros_test_pkgs@f2d3daf

Basically, I have a message definition md5_generation_issue/Test.msg which looks like this:

std_msgs/Int32 field
# std_msgs/Int32[] field
# std_msgs/Int32[1] field
# std_msgs/Int32[124] field

No matter which of the lines is uncommented (as long as it is only one), the md5-sum will always be 8b31b5679e76c808441b573f78ce35d1.

Is this a bug or a feature?

@dirk-thomas
Copy link
Member

Thank you for reporting this.
That is actually the current behavior of the md5sum calculation.
It only considers the "bare" type of fields but not the information if it is an array and what size the array has (

msg_type = bare_msg_type(type_)
).

I can't tell if that was an oversight in the first implementation or if there was any reason to do it (which I can't see any).

Anyway it is impossible at this point to change the behavior to differentiate those messages since that would essentially change the md5sum of most of the existing ROS messages.
But we will consider this for future development (aka ROS 2) since those different messages should indeed have different md5sums.

Therefore I will close this as "wontfix".

@vorzawk
Copy link

vorzawk commented Oct 12, 2021

@dirk-thomas I am facing this same issue currently. Is there a workaround for this issue?

@dirk-thomas
Copy link
Member

@vorzawk sorry, I am not the maintainer of this package anymore.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

3 participants