View Issue Details

IDProjectCategoryView StatusLast Update
0003291SketcherBugpublic2018-01-02 12:46
Reporterkalsan Assigned Toabdullah  
PrioritynormalSeveritycrashReproducibilityalways
Status closedResolutionfixed 
PlatformLaptopOSLinuxOS VersionArch Linux, newe
Product Version0.16 
Target Version0.17Fixed in Version0.17 
Summary0003291: Crash when deleting an edge in a nut
DescriptionWhen deleting Edge6 (the lower half circle) in the Sketch, the program crashes.
TagsNo tags attached.
FreeCAD Information

Activities

kalsan

2017-12-30 12:25

reporter  

arm.fcstd (3,387 bytes)

Kunda1

2017-12-30 17:04

administrator   ~0010634

@kalsan have you tried to reproduce this on the latest 0.17?

kalsan

2017-12-30 18:56

reporter   ~0010637

Unfortunately I cannot test due to missing capability to build the QT dependencies.

Kunda1

2017-12-31 00:49

administrator   ~0010640

@kaslan what OS are you on? If on linux, try the AppImage ( https://github.com/FreeCAD/FreeCAD/releases/tag/0.17_pre )

normandc

2017-12-31 13:31

manager   ~0010642

kalsan, as explained in the *huge* yellow banner that you couldn't possibly miss but did (quite a feat), you should have posted your full FreeCAD info.

I can reproduce the crash on the following system (using the Ubuntu freecad-daily PPA). Backtrace is attached.

OS: Ubuntu 16.04.3 LTS
Word size of OS: 64-bit
Word size of FreeCAD: 64-bit
Version: 0.17.12871 (Git)
Build type: None
Branch: master
Hash: 070395d67ca45826f1481da80aa9e0f6a9ef4292
Python version: 2.7.12
Qt version: 4.8.7
Coin version: 4.0.0a
OCC version: 7.1.0
Locale: French/Canada (fr_CA)
fc_tracker_3291_bt.txt (7,007 bytes)   
#0  0x00007ffff4727428 in __GI_raise (sig=sig@entry=6)
    at ../sysdeps/unix/sysv/linux/raise.c:54
#1  0x00007ffff472902a in __GI_abort () at abort.c:89
#2  0x00007ffff471fbd7 in __assert_fail_base (fmt=<optimized out>, 
    assertion=assertion@entry=0x7ffff42d3be8 "(index >= 0) && (index < this->getNumChildren())", file=file@entry=0x7ffff42d3b82 "SoGroup.cpp", 
    line=line@entry=292, 
    function=function@entry=0x7ffff42d3f80 "virtual SoNode* SoGroup::getChild(int) const") at assert.c:92
#3  0x00007ffff471fc82 in __GI___assert_fail (
    assertion=0x7ffff42d3be8 "(index >= 0) && (index < this->getNumChildren())", file=0x7ffff42d3b82 "SoGroup.cpp", line=292, 
    function=0x7ffff42d3f80 "virtual SoNode* SoGroup::getChild(int) const")
    at assert.c:101
#4  0x00007ffff3e01f98 in ?? () from /usr/lib/x86_64-linux-gnu/libCoin.so.80
#5  0x00007ffff405b151 in SoGroup::getChild(int) const ()
   from /usr/lib/x86_64-linux-gnu/libCoin.so.80
#6  0x00007fff56ec4c62 in SketcherGui::ViewProviderSketch::drawConstraintIcons() () from /usr/lib/freecad-daily/lib/SketcherGui.so
#7  0x00007fff56eccf23 in SketcherGui::ViewProviderSketch::draw(bool, bool) ()
   from /usr/lib/freecad-daily/lib/SketcherGui.so
#8  0x00007fff56ed79a7 in SketcherGui::ViewProviderSketch::updateData(App::Property const*) () from /usr/lib/freecad-daily/lib/SketcherGui.so
#9  0x00007ffff734b32f in Gui::Document::slotChangedObject(App::DocumentObject const&, App::Property const&) ()
   from /usr/lib/freecad-daily/lib/libFreeCADGui.so
#10 0x00007ffff6c5bed3 in boost::signal2<void, App::DocumentObject const&, App::Property const&, boost::last_value<void>, int, std::less<int>, boost::function<void (App::DocumentObject const&, App::Property const&)> >::operator()(App::DocumentObject const&, App::Property const&) ()
   from /usr/lib/freecad-daily/lib/libFreeCADApp.so
#11 0x00007ffff6c71861 in App::DocumentObject::onChanged(App::Property const*)
    () from /usr/lib/freecad-daily/lib/libFreeCADApp.so
#12 0x00007fffb84209bf in Part::Feature::onChanged(App::Property const*) ()
   from /usr/lib/freecad-daily/lib/Part.so
#13 0x00007fff57327739 in Sketcher::SketchObject::onChanged(App::Property const*) () from /usr/lib/freecad-daily/lib/Sketcher.so
#14 0x00007ffff6ced869 in App::Property::hasSetValue() ()
   from /usr/lib/freecad-daily/lib/libFreeCADApp.so
#15 0x00007fff5730c0e2 in Sketcher::SketchObject::transferConstraints(int, Sketcher::PointPos, int, Sketcher::PointPos) ()
   from /usr/lib/freecad-daily/lib/Sketcher.so
#16 0x00007fff573188f6 in Sketcher::SketchObject::delGeometry(int, bool) ()
   from /usr/lib/freecad-daily/lib/Sketcher.so
#17 0x00007fff573843ea in Sketcher::SketchObjectPy::delGeometry(_object*) ()
   from /usr/lib/freecad-daily/lib/Sketcher.so
#18 0x00007fff573848e7 in Sketcher::SketchObjectPy::staticCallback_delGeometry(_object*, _object*) () from /usr/lib/freecad-daily/lib/Sketcher.so
#19 0x00007ffff62ed961 in PyEval_EvalFrameEx ()
   from /usr/lib/x86_64-linux-gnu/libpython2.7.so.1.0
#20 0x00007ffff642304c in PyEval_EvalCodeEx ()
   from /usr/lib/x86_64-linux-gnu/libpython2.7.so.1.0
#21 0x00007ffff62e4d99 in PyEval_EvalCode ()
   from /usr/lib/x86_64-linux-gnu/libpython2.7.so.1.0
#22 0x00007ffff635f1e6 in PyRun_StringFlags ()
   from /usr/lib/x86_64-linux-gnu/libpython2.7.so.1.0
#23 0x00007ffff68757b6 in Base::InterpreterSingleton::runString[abi:cxx11](char const*) () from /usr/lib/freecad-daily/lib/libFreeCADBase.so
#24 0x00007ffff738b370 in Gui::Command::doCommand(Gui::Command::DoCmd_Type, char const*, ...) () from /usr/lib/freecad-daily/lib/libFreeCADGui.so
#25 0x00007fff56ed7e9e in SketcherGui::ViewProviderSketch::onDelete(std::vector<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> >, std::allocator<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > > > const&) () from /usr/lib/freecad-daily/lib/SketcherGui.so
#26 0x00007ffff7399307 in StdCmdDelete::activated(int) ()
   from /usr/lib/freecad-daily/lib/libFreeCADGui.so
#27 0x00007ffff738f6cc in Gui::Command::invoke(int) ()
   from /usr/lib/freecad-daily/lib/libFreeCADGui.so
#28 0x00007ffff51f3010 in QMetaObject::activate(QObject*, QMetaObject const*, int, void**) () from /usr/lib/x86_64-linux-gnu/libQtCore.so.4
#29 0x00007ffff5705d62 in QAction::triggered(bool) ()
   from /usr/lib/x86_64-linux-gnu/libQtGui.so.4
#30 0x00007ffff57070b3 in QAction::activate(QAction::ActionEvent) ()
   from /usr/lib/x86_64-linux-gnu/libQtGui.so.4
#31 0x00007ffff570760c in QAction::event(QEvent*) ()
   from /usr/lib/x86_64-linux-gnu/libQtGui.so.4
#32 0x00007ffff570bfdc in QApplicationPrivate::notify_helper(QObject*, QEvent*)
    () from /usr/lib/x86_64-linux-gnu/libQtGui.so.4
#33 0x00007ffff5712f16 in QApplication::notify(QObject*, QEvent*) ()
   from /usr/lib/x86_64-linux-gnu/libQtGui.so.4
#34 0x00007ffff736a484 in Gui::GUIApplication::notify(QObject*, QEvent*) ()
   from /usr/lib/freecad-daily/lib/libFreeCADGui.so
#35 0x00007ffff51de90d in QCoreApplication::notifyInternal(QObject*, QEvent*)
    () from /usr/lib/x86_64-linux-gnu/libQtCore.so.4
#36 0x00007ffff5742f18 in ?? () from /usr/lib/x86_64-linux-gnu/libQtGui.so.4
#37 0x00007ffff5743107 in ?? () from /usr/lib/x86_64-linux-gnu/libQtGui.so.4
#38 0x00007ffff57142ee in QApplication::notify(QObject*, QEvent*) ()
   from /usr/lib/x86_64-linux-gnu/libQtGui.so.4
#39 0x00007ffff736a484 in Gui::GUIApplication::notify(QObject*, QEvent*) ()
   from /usr/lib/freecad-daily/lib/libFreeCADGui.so
#40 0x00007ffff51de90d in QCoreApplication::notifyInternal(QObject*, QEvent*)
    () from /usr/lib/x86_64-linux-gnu/libQtCore.so.4
#41 0x00007ffff57b66b3 in ?? () from /usr/lib/x86_64-linux-gnu/libQtGui.so.4
#42 0x00007ffff57b6bc2 in ?? () from /usr/lib/x86_64-linux-gnu/libQtGui.so.4
#43 0x00007ffff578ed21 in QApplication::x11ProcessEvent(_XEvent*) ()
   from /usr/lib/x86_64-linux-gnu/libQtGui.so.4
#44 0x00007ffff57b9542 in ?? () from /usr/lib/x86_64-linux-gnu/libQtGui.so.4
#45 0x00007fffede48197 in g_main_context_dispatch ()
   from /lib/x86_64-linux-gnu/libglib-2.0.so.0
#46 0x00007fffede483f0 in ?? () from /lib/x86_64-linux-gnu/libglib-2.0.so.0
#47 0x00007fffede4849c in g_main_context_iteration ()
   from /lib/x86_64-linux-gnu/libglib-2.0.so.0
#48 0x00007ffff520f2ae in QEventDispatcherGlib::processEvents(QFlags<QEventLoop::ProcessEventsFlag>) () from /usr/lib/x86_64-linux-gnu/libQtCore.so.4
#49 0x00007ffff57b9616 in ?? () from /usr/lib/x86_64-linux-gnu/libQtGui.so.4
#50 0x00007ffff51dd18f in QEventLoop::processEvents(QFlags<QEventLoop::ProcessEventsFlag>) () from /usr/lib/x86_64-linux-gnu/libQtCore.so.4
#51 0x00007ffff51dd4f5 in QEventLoop::exec(QFlags<QEventLoop::ProcessEventsFlag>) () from /usr/lib/x86_64-linux-gnu/libQtCore.so.4
#52 0x00007ffff51e34b9 in QCoreApplication::exec() ()
   from /usr/lib/x86_64-linux-gnu/libQtCore.so.4
#53 0x00007ffff7323260 in Gui::Application::runApplication() ()
   from /usr/lib/freecad-daily/lib/libFreeCADGui.so
#54 0x0000000000403834 in main ()
fc_tracker_3291_bt.txt (7,007 bytes)   

normandc

2017-12-31 13:34

manager   ~0010643

If I delete Constraint18 first, then I can delete the lower arc without FreeCAD crashing.

Kunda1

2017-12-31 13:35

administrator   ~0010644

Thanks NormandC
@kalsan please follow the guidelines next time since it saves a lot of time for volunteers. Please open a forum thread to discuss this issue and link to this bugtracker. Thank you.

normandc

2017-12-31 13:40

manager   ~0010645

I can reliably reproduce this issue by replicating the sketch from the original file.

  1. Create new sketch
  2. Draw a rectangle
  3. Draw a vertical slot
  4. Select the lower left vertex of the slot, select the upper left vertex of the rectangle
  5. Apply a coincident constraint
  6. Select and delete the slot's lower arc
  7. Crash

abdullah

2017-12-31 18:01

manager   ~0010647

@normandc

Great job making this straight reproducible. Thanks and happy new year!

normandc

2017-12-31 18:03

manager   ~0010648

Thanks, Happy New Year to you too. I moved this report to Sketcher, but I wonder if it should rather go under GCS?

abdullah

2017-12-31 18:59

manager   ~0010649

@normandc

It is not a solver problem (but it could have been, I did not know it myself until debugging). In this case, it is the transferring of constraints that fails. The crash originates in coin3d and is the result of the transfer. The solver, GCS, is not to be blamed this time ;)

As a general rule, I think it is best that all the problems that are reported that happen in sketcher edit mode are reported to the sketcher project. Then, when the developer takes over the ticket he will know what the problem is and can decide whether to fix it or move it to gcs... Developers that are not managers can tag the tickets with "solver" so that a manager eventually moves them, or "summon" a manager asking for the transfer to gcs. This way we avoid that real sketcher bugs are not handled, as generally nobody looks often in the gcs bugs.

For this bug, I think I have a fix, I have rebased onto master, but with 2 cores and 1GB RAM, it takes forever to compile. Hopefully, I will be able to test the fix and do the pull request before CET new year...

abdullah

2017-12-31 20:09

manager   ~0010650

https://github.com/FreeCAD/FreeCAD/pull/1190

kalsan

2018-01-01 14:31

reporter   ~0010651

Thank you all for your great work and sorry for my negliction. I will consider the guidelines as well as #c10645 as a concrete example for future posts.

Happy new year everyone!

wmayer

2018-01-01 18:39

administrator   ~0010653

https://github.com/FreeCAD/FreeCAD/commit/9ce5756011c149925965bb46ba68e924a1a3271d

Issue History

Date Modified Username Field Change
2017-12-30 12:25 kalsan New Issue
2017-12-30 12:25 kalsan File Added: arm.fcstd
2017-12-30 17:04 Kunda1 Status new => feedback
2017-12-30 17:04 Kunda1 Note Added: 0010634
2017-12-30 18:56 kalsan Note Added: 0010637
2017-12-30 18:56 kalsan Status feedback => new
2017-12-31 00:49 Kunda1 Note Added: 0010640
2017-12-31 00:49 Kunda1 Status new => feedback
2017-12-31 13:31 normandc File Added: fc_tracker_3291_bt.txt
2017-12-31 13:31 normandc Note Added: 0010642
2017-12-31 13:33 Kunda1 Tag Attached: #post-to-forum
2017-12-31 13:34 normandc Note Added: 0010643
2017-12-31 13:35 Kunda1 Note Added: 0010644
2017-12-31 13:40 normandc Note Added: 0010645
2017-12-31 13:40 normandc Project PartDesign => Sketcher
2017-12-31 13:42 Kunda1 Status feedback => confirmed
2017-12-31 13:42 Kunda1 Target Version => 0.17
2017-12-31 18:00 abdullah Assigned To => abdullah
2017-12-31 18:00 abdullah Status confirmed => assigned
2017-12-31 18:01 abdullah Note Added: 0010647
2017-12-31 18:03 normandc Note Added: 0010648
2017-12-31 18:59 abdullah Note Added: 0010649
2017-12-31 20:09 abdullah Note Added: 0010650
2018-01-01 14:31 kalsan Note Added: 0010651
2018-01-01 18:39 wmayer Status assigned => closed
2018-01-01 18:39 wmayer Resolution open => fixed
2018-01-01 18:39 wmayer Fixed in Version => 0.17
2018-01-01 18:39 wmayer Note Added: 0010653
2018-01-02 12:46 Kunda1 Tag Detached: #post-to-forum