Fix complex member printing for DynamicDataHelper#2957
Fix complex member printing for DynamicDataHelper#2957MiguelCompany merged 5 commits intoeProsima:masterfrom
Conversation
Signed-off-by: Will Stott <willstott101@gmail.com>
Signed-off-by: methylDragon <methylDragon@gmail.com>
Signed-off-by: methylDragon <methylDragon@gmail.com>
|
I'm not sure why the tests are failing, they're nowhere close to what this PR has edited Probably flaky tests? |
Yes, those tests fail from time to time and are not related to this PR. Before we review, would you mind adding the changes from #2827, so we merge and backport both at the same time? |
…int' into ch3/hotfix-dynamic-data-helper
Merge conflicts fixed. |
|
@richiprosima Please test this |
|
@methylDragon Would you mind fixing the warnings on windows? |
Signed-off-by: methylDragon <methylDragon@gmail.com>
|
Let's try this df44d8c |
|
@richiprosima please test this |
MiguelCompany
left a comment
There was a problem hiding this comment.
LGTM. Thanks @methylDragon !
|
CH3EERS! I can't merge because I don't have write access 😬 |
|
@Mergifyio backport 2.7.x 2.6.x |
* DynamicDataHelper::print can print Sequences as well as Arrays Signed-off-by: Will Stott <willstott101@gmail.com> * Fix complex member printing Signed-off-by: methylDragon <methylDragon@gmail.com> * Clean up prints Signed-off-by: methylDragon <methylDragon@gmail.com> * Fix FastDDS windows CI error Signed-off-by: methylDragon <methylDragon@gmail.com> Signed-off-by: methylDragon <methylDragon@gmail.com> Co-authored-by: Will Stott <willstott101@gmail.com> (cherry picked from commit 78473a0)
* DynamicDataHelper::print can print Sequences as well as Arrays Signed-off-by: Will Stott <willstott101@gmail.com> * Fix complex member printing Signed-off-by: methylDragon <methylDragon@gmail.com> * Clean up prints Signed-off-by: methylDragon <methylDragon@gmail.com> * Fix FastDDS windows CI error Signed-off-by: methylDragon <methylDragon@gmail.com> Signed-off-by: methylDragon <methylDragon@gmail.com> Co-authored-by: Will Stott <willstott101@gmail.com> (cherry picked from commit 78473a0) # Conflicts: # src/cpp/dynamic-types/DynamicDataHelper.cpp
✅ Backports have been createdDetails
|
* Fix complex member printing for DynamicDataHelper (#2957) * DynamicDataHelper::print can print Sequences as well as Arrays Signed-off-by: Will Stott <willstott101@gmail.com> * Fix complex member printing Signed-off-by: methylDragon <methylDragon@gmail.com> * Clean up prints Signed-off-by: methylDragon <methylDragon@gmail.com> * Fix FastDDS windows CI error Signed-off-by: methylDragon <methylDragon@gmail.com> Signed-off-by: methylDragon <methylDragon@gmail.com> Co-authored-by: Will Stott <willstott101@gmail.com> (cherry picked from commit 78473a0) # Conflicts: # src/cpp/dynamic-types/DynamicDataHelper.cpp * Fix conflict Co-authored-by: methylDragon <methylDragon@gmail.com> * Fixing linters Signed-off-by: Miguel Company <MiguelCompany@eprosima.com> Signed-off-by: Miguel Company <MiguelCompany@eprosima.com> Co-authored-by: methylDragon <methylDragon@gmail.com> Co-authored-by: Miguel Company <miguelcompany@eprosima.com>
Description
This is a bugfix for the
DynamicDataHelper, needed for a dynamic types and type introspection reference implementation for ROS 2 as proposed in REP 2011.The printing methods for the helper segfault on attempting to print sequences of nested structs. This is because the
print_complex_member()function uses the wrongDynamicData*. With the changes that this PR introduces, the segfaults disappear.Additionally, this PR also cleans up the printing and adds useful tags for complex types.
Also, the
DynamicDataHelperstill has other bugs that are not addressed by this PR. Namely printing of dynamic sequences, which is addressed in #2827 .I've tested that PR, and it's ready to merge, despite being listed as DRAFT. The REP reference implementation would be expedited if that PR was also merged.
PS: There are no tests for
DynamicDataHelper, so I'm not implementing any in this PR.Suitable Backports
@Mergifyio backport (branch/2.7.x)
@Mergifyio backport (branch/2.6.x)
Maybe more...
Example
The following is an example printout of a triply nested DynamicData instance printed with this PR's fixes.
Contributor Checklist
versions.mdfile (if applicable).Reviewer Checklist