gazebosim / gazebo-classic

Gazebo classic. For the latest version, see https://github.com/gazebosim/gz-sim
http://classic.gazebosim.org/
Other
1.17k stars 476 forks source link

Model Editor crashes if swap joint child-parent is used #2065

Open osrf-migration opened 7 years ago

osrf-migration commented 7 years ago

Original report (archived issue) by Louise Poubel (Bitbucket: chapulina, GitHub: chapulina).


  1. Enter model editor

  2. Insert 2 links

  3. Open joint creation dialog

  4. Click on one link for child, the other for parent

  5. Then click on the swap button to swap parent and child

  6. Create the joint

  7. Ctrl+X to exit the editor, choose to save

  8. Gazebo crashes. Backtrace:

Thread 1 "gzclient" received signal SIGSEGV, Segmentation fault.
0x00007fffcee2e837 in Ogre::OctreeNode::_removeNodeAndChildren() ()
   from /usr/lib/x86_64-linux-gnu/OGRE-1.9.0/Plugin_OctreeSceneManager.so
(gdb) bt
#0  0x00007fffcee2e837 in Ogre::OctreeNode::_removeNodeAndChildren() ()
   from /usr/lib/x86_64-linux-gnu/OGRE-1.9.0/Plugin_OctreeSceneManager.so
#1  0x00007fffcee2eb91 in Ogre::OctreeNode::removeChild(Ogre::Node*) ()
   from /usr/lib/x86_64-linux-gnu/OGRE-1.9.0/Plugin_OctreeSceneManager.so
#2  0x00007ffff50e9216 in gazebo::rendering::Visual::DetachVisual (this=this@entry=0x4a0e7a0, 
    _name="ModelPreview_0::_JOINT_VISUAL_") at /home/osrf/code/gazebo/gazebo/rendering/Visual.cc:602
#3  0x00007ffff50e93c2 in gazebo::rendering::Visual::DetachVisual (this=this@entry=0x4a0e7a0, 
    _vis=std::shared_ptr (count 3, weak 1) 0x63bd0a0)
    at /home/osrf/code/gazebo/gazebo/rendering/Visual.cc:588
#4  0x00007ffff50e9510 in gazebo::rendering::Visual::Fini (this=0x4a0e7a0)
    at /home/osrf/code/gazebo/gazebo/rendering/Visual.cc:194
#5  0x00007ffff50a8ab3 in gazebo::rendering::Scene::RemoveVisual (this=0x1ca83b0, _id=<optimized out>)
    at /home/osrf/code/gazebo/gazebo/rendering/Scene.cc:3108
#6  0x00007ffff50a8d27 in gazebo::rendering::Scene::RemoveVisual (this=<optimized out>, 
    _vis=std::shared_ptr (count 4, weak 1) 0x4a0e7a0)
    at /home/osrf/code/gazebo/gazebo/rendering/Scene.cc:3119
#7  0x00007ffff73b1122 in gazebo::gui::ModelCreator::RemoveLinkImpl (this=this@entry=0x4446e80, 
    _linkName=...) at /home/osrf/code/gazebo/gazebo/gui/model/ModelCreator.cc:1559
#8  0x00007ffff73adb13 in gazebo::gui::ModelCreator::Reset (this=this@entry=0x4446e80)
    at /home/osrf/code/gazebo/gazebo/gui/model/ModelCreator.cc:1615
#9  0x00007ffff73bc0ba in gazebo::gui::ModelCreator::FinishModel (this=this@entry=0x4446e80)
    at /home/osrf/code/gazebo/gazebo/gui/model/ModelCreator.cc:1732
#10 0x00007ffff73c259a in gazebo::gui::ModelCreator::OnExit (this=0x4446e80)
    at /home/osrf/code/gazebo/gazebo/gui/model/ModelCreator.cc:930
#11 0x00007ffff73d8c39 in std::function<void ()>::operator()() const (this=<optimized out>)
    at /usr/include/c++/5/functional:2267
#12 gazebo::event::EventT<void ()>::Signal() (this=<optimized out>)
    at /home/osrf/code/gazebo/gazebo/common/Event.hh:299
#13 gazebo::event::EventT<void ()>::operator()() (this=<optimized out>)
    at /home/osrf/code/gazebo/gazebo/common/Event.hh:143
#14 gazebo::gui::ModelEditor::Exit (this=<optimized out>)
    at /home/osrf/code/gazebo/gazebo/gui/model/ModelEditor.cc:315
#15 0x00007ffff6a85010 in QMetaObject::activate(QObject*, QMetaObject const*, int, void**) ()
   from /usr/lib/x86_64-linux-gnu/libQtCore.so.4
#16 0x00007ffff442bd62 in QAction::triggered(bool) () from /usr/lib/x86_64-linux-gnu/libQtGui.so.4
#17 0x00007ffff442d0b3 in QAction::activate(QAction::ActionEvent) ()
   from /usr/lib/x86_64-linux-gnu/libQtGui.so.4
#18 0x00007ffff442d60c in QAction::event(QEvent*) () from /usr/lib/x86_64-linux-gnu/libQtGui.so.4
#19 0x00007ffff4431fdc in QApplicationPrivate::notify_helper(QObject*, QEvent*) ()
   from /usr/lib/x86_64-linux-gnu/libQtGui.so.4
#20 0x00007ffff4438f16 in QApplication::notify(QObject*, QEvent*) ()
   from /usr/lib/x86_64-linux-gnu/libQtGui.so.4
#21 0x00007ffff6a7090d in QCoreApplication::notifyInternal(QObject*, QEvent*) ()
   from /usr/lib/x86_64-linux-gnu/libQtCore.so.4
#22 0x00007ffff4468f18 in ?? () from /usr/lib/x86_64-linux-gnu/libQtGui.so.4
#23 0x00007ffff4469107 in ?? () from /usr/lib/x86_64-linux-gnu/libQtGui.so.4
#24 0x00007ffff443a2ee in QApplication::notify(QObject*, QEvent*) ()
   from /usr/lib/x86_64-linux-gnu/libQtGui.so.4
#25 0x00007ffff6a7090d in QCoreApplication::notifyInternal(QObject*, QEvent*) ()
   from /usr/lib/x86_64-linux-gnu/libQtCore.so.4
#26 0x00007ffff44dc6b3 in ?? () from /usr/lib/x86_64-linux-gnu/libQtGui.so.4
#27 0x00007ffff44dcbc2 in ?? () from /usr/lib/x86_64-linux-gnu/libQtGui.so.4
#28 0x00007ffff44b4d21 in QApplication::x11ProcessEvent(_XEvent*) ()
   from /usr/lib/x86_64-linux-gnu/libQtGui.so.4
#29 0x00007ffff44df542 in ?? () from /usr/lib/x86_64-linux-gnu/libQtGui.so.4
#30 0x00007fffee6ee1a7 in g_main_context_dispatch () from /lib/x86_64-linux-gnu/libglib-2.0.so.0
#31 0x00007fffee6ee400 in ?? () from /lib/x86_64-linux-gnu/libglib-2.0.so.0
---Type <return> to continue, or q <return> to quit---
#32 0x00007fffee6ee4ac in g_main_context_iteration () from /lib/x86_64-linux-gnu/libglib-2.0.so.0
#33 0x00007ffff6aa12ae in QEventDispatcherGlib::processEvents(QFlags<QEventLoop::ProcessEventsFlag>) ()
   from /usr/lib/x86_64-linux-gnu/libQtCore.so.4
#34 0x00007ffff44df616 in ?? () from /usr/lib/x86_64-linux-gnu/libQtGui.so.4
#35 0x00007ffff6a6f18f in QEventLoop::processEvents(QFlags<QEventLoop::ProcessEventsFlag>) ()
   from /usr/lib/x86_64-linux-gnu/libQtCore.so.4
#36 0x00007ffff6a6f4f5 in QEventLoop::exec(QFlags<QEventLoop::ProcessEventsFlag>) ()
   from /usr/lib/x86_64-linux-gnu/libQtCore.so.4
#37 0x00007ffff6a754b9 in QCoreApplication::exec() () from /usr/lib/x86_64-linux-gnu/libQtCore.so.4
#38 0x00007ffff7255e53 in gazebo::gui::run (_argc=<optimized out>, _argv=0x7fffffffe558)
    at /home/osrf/code/gazebo/gazebo/gui/GuiIface.cc:367
#39 0x000000000040274c in main (_argc=1, _argv=0x7fffffffe558)
    at /home/osrf/code/gazebo/gazebo/gui/main.cc:29
osrf-migration commented 7 years ago

Original comment by Louise Poubel (Bitbucket: chapulina, GitHub: chapulina).


osrf-migration commented 6 years ago

Original comment by Mrunmayi Mungekar (Bitbucket: mrunzzz).


I tried replicating the issue. Gazebo didn't crash for me. IS this error persisting in gazebo 10 or an older version? Is there any way to show you a screen recording? The comment doesn't support videos.

Step1:Screenshot from 2018-04-14 00:08:36.037368.mkv - 1.png

After Swap:Screenshot from 2018-04-14 00:08:36.037368.mkv - 2.png

After Save and Exit:Screenshot from 2018-04-14 00:08:36.037368.mkv.png

osrf-migration commented 6 years ago

Original comment by Louise Poubel (Bitbucket: chapulina, GitHub: chapulina).


Thank you for looking into this! I also tried reproducing the issue on Gazebo 8 and there was no problem; I suspect by the issue's date that it was a problem on Gazebo 7. If no one can reproduce on 7 we can close it!

As for your question about videos, I usually post gifs instead. A nice tool for creating gifs on Ubuntu is Peek.