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

Updating worlds after model reorg #80

Merged
merged 9 commits into from
Aug 23, 2022
Merged

Conversation

quarkytale
Copy link
Contributor

@quarkytale quarkytale commented Aug 9, 2022

  • Bug fix for robot_state_publisher dying, unable to find the model after reorganization.
Error [SDF.cc:160] Tried to use callback in sdf::findFile(), but the callback is empty.  Did you call sdf::setFindCallback()?
Error Code 13: [/sdf/world[@name="world_demo"]/model[@name="MBARI_WEC_ROS"]/include[0]/uri:/home/anderson/wec/igngzb/openrobotics/workspace/src/buoy_sim/buoy_gazebo/worlds/mbari_wec.sdf:L49]: Msg: Unable to find 
  • Updating other worlds, launch files and making sure they work as expected.

@quarkytale quarkytale self-assigned this Aug 9, 2022
Signed-off-by: Dharini Dutia <[email protected]>
Signed-off-by: Dharini Dutia <[email protected]>
Signed-off-by: Dharini Dutia <[email protected]>
Signed-off-by: Dharini Dutia <[email protected]>
@quarkytale quarkytale marked this pull request as ready for review August 10, 2022 07:31
@quarkytale
Copy link
Contributor Author

So rviz isn't running as expected robot_state_publisher is looking for mbari_wec model as opposed to mbari_wec_ros, sorry this error slipped from me earlier. I'm still debugging but opening this up if anyone can take a glance.

@andermi
Copy link
Collaborator

andermi commented Aug 17, 2022

Unfortunately, the error is back that I mentioned in #74 , and I can't figure out what's causing it

Error:   Could not find the 'robot' element in the xml file
         at line 80 in /tmp/binarydeb/ros-galactic-urdfdom-2.3.5/urdf_parser/src/model.cpp
Failed to parse robot description using: urdf_xml_parser/URDFXMLParser
terminate called after throwing an instance of 'std::runtime_error'
  what():  Unable to initialize urdf::model from robot description

I actually can't find where the parser plugin is actually converting sdf to urdf referenced by this comment:
https://github.com/osrf/buoy_sim/blob/8bffa32e5d9a47a564482c55ad6d7770c6e4280d/buoy_gazebo/launch/mbari_wec.launch.py#L91-L92

@quarkytale
Copy link
Contributor Author

quarkytale commented Aug 19, 2022

I actually can't find where the parser plugin is actually converting sdf to urdf referenced by this comment:

When a SDF if published on the robot_description topic, robot_state_publisher checks in the list of available parsers which can parse the message and uses sdformat_urdf from that list (afaik).

This is actually a very inconsistent error, looking into it.

@quarkytale
Copy link
Contributor Author

Some updates on this

  • The issue with ign sdf callback failing is SDF can't parse the package:// path. A quick fix is to create and set an env variable SDF_PATH the same as IGN_GAZEBO_RESOURCE_PATH. This seems like a bug I'll take it up.
  • With the Could not find the 'robot' element in the xml file issue, its essentially the workspace not being sourced or sdformat_urdf not installed. Make sure to install deps via rosdep too.

Signed-off-by: Dharini Dutia <[email protected]>
@quarkytale
Copy link
Contributor Author

Just pushed a fix, needed to add another path to the IGN_GAZEBO_RESOURCE_PATH, solves the rviz problem as well.

@andermi
Copy link
Collaborator

andermi commented Aug 22, 2022

The tests should pass after I merge #85 and you merge main into your branch

@quarkytale
Copy link
Contributor Author

Ahh you beat me to it, thanks!

@quarkytale quarkytale merged commit d6acbdd into main Aug 23, 2022
@quarkytale quarkytale deleted the quarkytale/worlds_bug_fix branch August 23, 2022 01:49
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants