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

Reduce/Eliminate sdf::Model and sdf::World serialization warnings #2742

Merged
merged 6 commits into from
Jan 31, 2025

Conversation

azeey
Copy link
Contributor

@azeey azeey commented Jan 29, 2025

🦟 Bug fix

Summary

Currently, when running any world in Gazebo, we get warnings similar to the following

(2025-01-28 23:15:59.539) [warning] [Model.hh:69] Skipping serialization / deserialization for models with //pose/@relative_to attribute.
(2025-01-28 23:15:59.540) [warning] [Component.hh:144] Trying to serialize component with data type [N3sdf3v155WorldE], which doesn't have `operator<<`. Component will not be serialized.

This PR:

  • Reduces serialization warnings on sdf::Model so it only occurs when the relative_to attribute is set. This was the intended behavior originally, but there was a bug in the code.
  • Eliminate sdf::World warnings by specializing the DefaultSerializer for sdf::World.

Checklist

  • Signed all commits for DCO
  • Added tests
  • Updated documentation (as needed)
  • Updated migration guide (as needed)
  • Consider updating Python bindings (if the library has them)
  • codecheck passed (See contributing)
  • All tests passed (See test coverage)
  • While waiting for a review on your PR, please help review another open pull request to support the maintainers

Note to maintainers: Remember to use Squash-Merge and edit the commit message to match the pull request summary while retaining Signed-off-by messages.

- Reduces serialization warnings on `sdf::Model` so it only occurs when
  the `relative_to` attribute is set. This was the intended behavior
  originally, but there was a bug in the code.
- Eliminate `sdf::World` warnings by specializing the `DefaultSerializer` for `sdf::World`.

Signed-off-by: Addisu Z. Taddese <[email protected]>
@azeey azeey requested a review from mjcarroll as a code owner January 29, 2025 05:17
@github-actions github-actions bot added the 🏛️ ionic Gazebo Ionic label Jan 29, 2025
Signed-off-by: Addisu Z. Taddese <[email protected]>
@azeey
Copy link
Contributor Author

azeey commented Jan 30, 2025

The ABI checker is failing with

Removed Symbols  2 
Component.hh
namespace gz::sim::v9::traits
IsInStreamable<std::istream, sdf::v15::World>::value [data]
_ZN2gz3sim2v96traits14IsInStreamableISiN3sdf3v155WorldEE5valueE

IsOutStreamable<std::ostream, sdf::v15::World>::value [data]
_ZN2gz3sim2v96traits15IsOutStreamableISoN3sdf3v155WorldEE5valueE

It looks like a false positive, but I'm not a 100% sure. I've attempted a workaround in e1c7f91

@azeey azeey merged commit 1739bdb into gazebosim:gz-sim9 Jan 31, 2025
11 checks passed
@azeey azeey deleted the fix_serialization_warnings branch January 31, 2025 03:25
@azeey
Copy link
Contributor Author

azeey commented Jan 31, 2025

@Mergifyio backport gz-sim8 ign-gazebo6

Copy link
Contributor

mergify bot commented Jan 31, 2025

backport gz-sim8 ign-gazebo6

✅ Backports have been created

mergify bot pushed a commit that referenced this pull request Jan 31, 2025
…#2742)

- Reduces serialization warnings on `sdf::Model` so it only occurs when
  the `relative_to` attribute is set. This was the intended behavior
  originally, but there was a bug in the code.
- Eliminate `sdf::World` warnings by specializing the `DefaultSerializer` for `sdf::World`.

---------

Signed-off-by: Addisu Z. Taddese <[email protected]>
(cherry picked from commit 1739bdb)
mergify bot pushed a commit that referenced this pull request Jan 31, 2025
…#2742)

- Reduces serialization warnings on `sdf::Model` so it only occurs when
  the `relative_to` attribute is set. This was the intended behavior
  originally, but there was a bug in the code.
- Eliminate `sdf::World` warnings by specializing the `DefaultSerializer` for `sdf::World`.

---------

Signed-off-by: Addisu Z. Taddese <[email protected]>
(cherry picked from commit 1739bdb)

# Conflicts:
#	include/gz/sim/components/World.hh
azeey added a commit that referenced this pull request Feb 1, 2025
…#2742)

- Reduces serialization warnings on `sdf::Model` so it only occurs when
  the `relative_to` attribute is set. This was the intended behavior
  originally, but there was a bug in the code.
- Eliminate `sdf::World` warnings by specializing the `DefaultSerializer` for `sdf::World`.

---------

Signed-off-by: Addisu Z. Taddese <[email protected]>
(cherry picked from commit 1739bdb)
azeey added a commit that referenced this pull request Feb 1, 2025
…#2742)

- Reduces serialization warnings on `sdf::Model` so it only occurs when
  the `relative_to` attribute is set. This was the intended behavior
  originally, but there was a bug in the code.
- Eliminate `sdf::World` warnings by specializing the `DefaultSerializer` for `sdf::World`.

---------

Signed-off-by: Addisu Z. Taddese <[email protected]>
(cherry picked from commit 1739bdb)
Signed-off-by: Addisu Z. Taddese <[email protected]>
azeey added a commit that referenced this pull request Feb 5, 2025
…#2742)

- Reduces serialization warnings on `sdf::Model` so it only occurs when
  the `relative_to` attribute is set. This was the intended behavior
  originally, but there was a bug in the code.
- Eliminate `sdf::World` warnings by specializing the `DefaultSerializer` for `sdf::World`.

---------

Signed-off-by: Addisu Z. Taddese <[email protected]>
(cherry picked from commit 1739bdb)
Signed-off-by: Addisu Z. Taddese <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
🏛️ ionic Gazebo Ionic
Projects
Status: Done
Development

Successfully merging this pull request may close these issues.

3 participants