View Issue Details

IDProjectCategoryView StatusLast Update
0004523PartDesignBugpublic2021-02-06 06:43
Reporterrobryk Assigned To 
PrioritynormalSeveritycrashReproducibilityalways
Status newResolutionopen 
Platformx86_64OSNixOSOS Versionrelease-20.09
Target Version0.20 
Summary0004523: Crash (SIGSEGV) when moving elements of a constrained sketch
DescriptionThe crash seems to be triggered by movement of points of lines that are involved in reference constraints *and* have points constrained to lie on them. It seems that the crash can be prevented by saving the project between subsequent operations (see repro instructions for more details).
Steps To Reproduce1. Create a new project, enable Part Design workbench, create a body and a sketch.
2. Create a line. (The issue reproduces both for lines with no constraints and lines with a vertical constraint.)
3. Create a point constrained to stay on the line. (The issue doesn't reproduce with line alone.)
4. Create a reference constraint for the length of the line. (The issue doesn't reproduce for non-reference constraints.)
5. Optionally: save the project. The attached project was saved at this stage.
6. Add a name to the constraint.
7. Do _not_ save the project again. (Saving appears to prevent the issue from occurring.)
8. Drag one of the ends of the line around until FreeCAD crashes (usually takes 0-5 seconds).

What happens:
FreeCAD prints "Program received signal SIGSEGV, Segmentation fault." and either
a) hangs, or
b) prints a backtrace and exits.
Additional InformationMy FreeCAD is compiled from commit 7616153b3c31ace006169cdc2fdafab484498858. I haven't tried the current tip of the master branch, because compiling would take a long time for me right now.

Backtrace:


Program received signal SIGSEGV, Segmentation fault.
#0  /nix/store/33idnvrkvfgd5lsx2pwgwwi955adl6sk-glibc-2.31/lib/libc.so.6(+0x380f0) [0x7fc5238270f0]
#1  0x7fc5258b4a05 in SoBaseList::operator[](int) const from /nix/store/yzi7nsv752xn4qcxk83vxbggd22hbmv3-coin-4.0.0/lib/libCoin.so.80+0x15
0000002  0x7fc5258c3605 in SoChildList::truncate(int) from /nix/store/yzi7nsv752xn4qcxk83vxbggd22hbmv3-coin-4.0.0/lib/libCoin.so.80+0x45
0000003  0x7fc5258c36ab in SoChildList::~SoChildList() from /nix/store/yzi7nsv752xn4qcxk83vxbggd22hbmv3-coin-4.0.0/lib/libCoin.so.80+0xb
0000004  0x7fc52590eef9 in SoGroup::~SoGroup() from /nix/store/yzi7nsv752xn4qcxk83vxbggd22hbmv3-coin-4.0.0/lib/libCoin.so.80+0x29
0000005  0x7fc5259295b9 in SoSeparator::~SoSeparator() from /nix/store/yzi7nsv752xn4qcxk83vxbggd22hbmv3-coin-4.0.0/lib/libCoin.so.80+0x9
0000006  0x7fc5258bf079 in SoBase::destroy() from /nix/store/yzi7nsv752xn4qcxk83vxbggd22hbmv3-coin-4.0.0/lib/libCoin.so.80+0x99
0000007  0x7fc5258b49b2 in SoBaseList::truncate(int) from /nix/store/yzi7nsv752xn4qcxk83vxbggd22hbmv3-coin-4.0.0/lib/libCoin.so.80+0x52
0000008  0x7fc5258cfcaf in SoPath::truncate(int, int) from /nix/store/yzi7nsv752xn4qcxk83vxbggd22hbmv3-coin-4.0.0/lib/libCoin.so.80+0x6f
0000009  0x7fc5258cfd49 in SoPath::~SoPath() from /nix/store/yzi7nsv752xn4qcxk83vxbggd22hbmv3-coin-4.0.0/lib/libCoin.so.80+0x19
0000010  0x7fc5258cfd89 in SoPath::~SoPath() from /nix/store/yzi7nsv752xn4qcxk83vxbggd22hbmv3-coin-4.0.0/lib/libCoin.so.80+0x9
0000011  0x7fc5258bf079 in SoBase::destroy() from /nix/store/yzi7nsv752xn4qcxk83vxbggd22hbmv3-coin-4.0.0/lib/libCoin.so.80+0x99
0000012  0x7fc5258d234d in SoPickedPoint::~SoPickedPoint() from /nix/store/yzi7nsv752xn4qcxk83vxbggd22hbmv3-coin-4.0.0/lib/libCoin.so.80+0xd
0000013  0x7fc4626c365f in SketcherGui::ViewProviderSketch::mouseButtonPressed(int, bool, SbVec2s const&, Gui::View3DInventorViewer const*) from /nix/store/knmz55iw0kq4k1y0dpsvvzgzr4x1bak5-freecad-unstable-2020-09-25/lib/SketcherGui.so+0x17f
0000014  0x7fc5276312be in Gui::ViewProvider::eventCallback(void*, SoEventCallback*) from /nix/store/knmz55iw0kq4k1y0dpsvvzgzr4x1bak5-freecad-unstable-2020-09-25/lib/libFreeCADGui.so+0x12e
0000015  0x7fc525906761 in SoEventCallback::handleEvent(SoHandleEventAction*) from /nix/store/yzi7nsv752xn4qcxk83vxbggd22hbmv3-coin-4.0.0/lib/libCoin.so.80+0xc1
0000016  0x7fc5256f8e85 in SoAction::traverse(SoNode*) from /nix/store/yzi7nsv752xn4qcxk83vxbggd22hbmv3-coin-4.0.0/lib/libCoin.so.80+0x65
0000017  0x7fc5258c3af8 in SoChildList::traverse(SoAction*, int, int) from /nix/store/yzi7nsv752xn4qcxk83vxbggd22hbmv3-coin-4.0.0/lib/libCoin.so.80+0x168
0000018  0x7fc52590f2b8 in SoGroup::doAction(SoAction*) from /nix/store/yzi7nsv752xn4qcxk83vxbggd22hbmv3-coin-4.0.0/lib/libCoin.so.80+0x58
0000019  0x7fc5259295f8 in SoSeparator::doAction(SoAction*) from /nix/store/yzi7nsv752xn4qcxk83vxbggd22hbmv3-coin-4.0.0/lib/libCoin.so.80+0x28
0000020  0x7fc527552210 in Gui::SoFCUnifiedSelection::handleEvent(SoHandleEventAction*) from /nix/store/knmz55iw0kq4k1y0dpsvvzgzr4x1bak5-freecad-unstable-2020-09-25/lib/libFreeCADGui.so+0x90
0000021  0x7fc5256f8e85 in SoAction::traverse(SoNode*) from /nix/store/yzi7nsv752xn4qcxk83vxbggd22hbmv3-coin-4.0.0/lib/libCoin.so.80+0x65
0000022  0x7fc5258c3af8 in SoChildList::traverse(SoAction*, int, int) from /nix/store/yzi7nsv752xn4qcxk83vxbggd22hbmv3-coin-4.0.0/lib/libCoin.so.80+0x168
0000023  0x7fc52590f2b8 in SoGroup::doAction(SoAction*) from /nix/store/yzi7nsv752xn4qcxk83vxbggd22hbmv3-coin-4.0.0/lib/libCoin.so.80+0x58
0000024  0x7fc5259295f8 in SoSeparator::doAction(SoAction*) from /nix/store/yzi7nsv752xn4qcxk83vxbggd22hbmv3-coin-4.0.0/lib/libCoin.so.80+0x28
0000025  0x7fc5256f8e85 in SoAction::traverse(SoNode*) from /nix/store/yzi7nsv752xn4qcxk83vxbggd22hbmv3-coin-4.0.0/lib/libCoin.so.80+0x65
0000026  0x7fc5257025d3 in SoHandleEventAction::beginTraversal(SoNode*) from /nix/store/yzi7nsv752xn4qcxk83vxbggd22hbmv3-coin-4.0.0/lib/libCoin.so.80+0xa3
0000027  0x7fc5256f9ac2 in SoAction::apply(SoNode*) from /nix/store/yzi7nsv752xn4qcxk83vxbggd22hbmv3-coin-4.0.0/lib/libCoin.so.80+0x2d2
0000028  0x7fc5258dc3d9 in SoEventManager::actuallyProcessEvent(SoEvent const*) from /nix/store/yzi7nsv752xn4qcxk83vxbggd22hbmv3-coin-4.0.0/lib/libCoin.so.80+0x69
0000029  0x7fc5275cf73e in SIM::Coin3D::Quarter::QuarterWidget::processSoEvent(SoEvent const*) from /nix/store/knmz55iw0kq4k1y0dpsvvzgzr4x1bak5-freecad-unstable-2020-09-25/lib/libFreeCADGui.so+0x1e
0000030  0x7fc5275d7bf7 in SIM::Coin3D::Quarter::SoQTQuarterAdaptor::processSoEvent(SoEvent const*) from /nix/store/knmz55iw0kq4k1y0dpsvvzgzr4x1bak5-freecad-unstable-2020-09-25/lib/libFreeCADGui.so+0x57
0000031  0x7fc52760b7e9 in Gui::View3DInventorViewer::processSoEventBase(SoEvent const*) from /nix/store/knmz55iw0kq4k1y0dpsvvzgzr4x1bak5-freecad-unstable-2020-09-25/lib/libFreeCADGui.so+0x9
0000032  0x7fc5275e028c in Gui::NavigationStyle::processSoEvent(SoEvent const*) from /nix/store/knmz55iw0kq4k1y0dpsvvzgzr4x1bak5-freecad-unstable-2020-09-25/lib/libFreeCADGui.so+0xbc
0000033  0x7fc5275e558b in Gui::CADNavigationStyle::processSoEvent(SoEvent const*) from /nix/store/knmz55iw0kq4k1y0dpsvvzgzr4x1bak5-freecad-unstable-2020-09-25/lib/libFreeCADGui.so+0x31b
0000034  0x7fc5275e2245 in Gui::NavigationStyle::processEvent(SoEvent const*) from /nix/store/knmz55iw0kq4k1y0dpsvvzgzr4x1bak5-freecad-unstable-2020-09-25/lib/libFreeCADGui.so+0x75
0000035  0x7fc52760b75c in Gui::View3DInventorViewer::processSoEvent(SoEvent const*) from /nix/store/knmz55iw0kq4k1y0dpsvvzgzr4x1bak5-freecad-unstable-2020-09-25/lib/libFreeCADGui.so+0x6c
0000036  0x7fc5275c86b1 in SIM::Coin3D::Quarter::EventFilter::eventFilter(QObject*, QEvent*) from /nix/store/knmz55iw0kq4k1y0dpsvvzgzr4x1bak5-freecad-unstable-2020-09-25/lib/libFreeCADGui.so+0xd1
0000037  0x7fc5240a156b in QCoreApplicationPrivate::sendThroughObjectEventFilters(QObject*, QEvent*) from /nix/store/m1bvfyy6m7j3r75x72npprnmqvm7ql2a-qtbase-5.15.0/lib/libQt5Core.so.5+0x9b
0000038  0x7fc524b60cde in QApplicationPrivate::notify_helper(QObject*, QEvent*) from /nix/store/m1bvfyy6m7j3r75x72npprnmqvm7ql2a-qtbase-5.15.0/lib/libQt5Widgets.so.5+0x6e
#39  0x7fc524b69da3 in QApplication::notify(QObject*, QEvent*) from /nix/store/m1bvfyy6m7j3r75x72npprnmqvm7ql2a-qtbase-5.15.0/lib/libQt5Widgets.so.5+0x583
#40  0x7fc5272fb998 in Gui::GUIApplication::notify(QObject*, QEvent*) from /nix/store/knmz55iw0kq4k1y0dpsvvzgzr4x1bak5-freecad-unstable-2020-09-25/lib/libFreeCADGui.so+0x88
0000041  0x7fc5240a17fa in QCoreApplication::notifyInternal2(QObject*, QEvent*) from /nix/store/m1bvfyy6m7j3r75x72npprnmqvm7ql2a-qtbase-5.15.0/lib/libQt5Core.so.5+0x12a
0000042  0x7fc524b68eb7 in QApplicationPrivate::sendMouseEvent(QWidget*, QMouseEvent*, QWidget*, QWidget*, QWidget**, QPointer<QWidget>&, bool, bool) from /nix/store/m1bvfyy6m7j3r75x72npprnmqvm7ql2a-qtbase-5.15.0/lib/libQt5Widgets.so.5+0x1b7
0000043  /nix/store/m1bvfyy6m7j3r75x72npprnmqvm7ql2a-qtbase-5.15.0/lib/libQt5Widgets.so.5(+0x1cfe19) [0x7fc524bbde19]
0000044  /nix/store/m1bvfyy6m7j3r75x72npprnmqvm7ql2a-qtbase-5.15.0/lib/libQt5Widgets.so.5(+0x1d3114) [0x7fc524bc1114]
0000045  0x7fc524b60cef in QApplicationPrivate::notify_helper(QObject*, QEvent*) from /nix/store/m1bvfyy6m7j3r75x72npprnmqvm7ql2a-qtbase-5.15.0/lib/libQt5Widgets.so.5+0x7f
0000046  0x7fc524b69b50 in QApplication::notify(QObject*, QEvent*) from /nix/store/m1bvfyy6m7j3r75x72npprnmqvm7ql2a-qtbase-5.15.0/lib/libQt5Widgets.so.5+0x330
0000047  0x7fc5272fb998 in Gui::GUIApplication::notify(QObject*, QEvent*) from /nix/store/knmz55iw0kq4k1y0dpsvvzgzr4x1bak5-freecad-unstable-2020-09-25/lib/libFreeCADGui.so+0x88
0000048  0x7fc5240a17fa in QCoreApplication::notifyInternal2(QObject*, QEvent*) from /nix/store/m1bvfyy6m7j3r75x72npprnmqvm7ql2a-qtbase-5.15.0/lib/libQt5Core.so.5+0x12a
0000049  0x7fc5244c1013 in QGuiApplicationPrivate::processMouseEvent(QWindowSystemInterfacePrivate::MouseEvent*) from /nix/store/m1bvfyy6m7j3r75x72npprnmqvm7ql2a-qtbase-5.15.0/lib/libQt5Gui.so.5+0x6c3
0000050  0x7fc5244c0b48 in QGuiApplicationPrivate::processMouseEvent(QWindowSystemInterfacePrivate::MouseEvent*) from /nix/store/m1bvfyy6m7j3r75x72npprnmqvm7ql2a-qtbase-5.15.0/lib/libQt5Gui.so.5+0x1f8
0000051  0x7fc5244c26a5 in QGuiApplicationPrivate::processWindowSystemEvent(QWindowSystemInterfacePrivate::WindowSystemEvent*) from /nix/store/m1bvfyy6m7j3r75x72npprnmqvm7ql2a-qtbase-5.15.0/lib/libQt5Gui.so.5+0x255
0000052  0x7fc52449adab in QWindowSystemInterface::sendWindowSystemEvents(QFlags<QEventLoop::ProcessEventsFlag>) from /nix/store/m1bvfyy6m7j3r75x72npprnmqvm7ql2a-qtbase-5.15.0/lib/libQt5Gui.so.5+0xbb
0000053  /nix/store/fl7g5dqfbxa52c5dmcg98cb6p701hgzn-qtbase-5.15.0-bin/lib/qt-5.15.0/plugins/platforms/../../../../../m1bvfyy6m7j3r75x72npprnmqvm7ql2a-qtbase-5.15.0/lib/libQt5XcbQpa.so.5(+0x6973a) [0x7fc511de173a]
0000054  /nix/store/fzxhbcyzsfv1v8523jxlzvpsmvfhx2pz-glib-2.64.5/lib/libglib-2.0.so.0(g_main_context_dispatch+0x27d) [0x7fc520a4f44d]
0000055  /nix/store/fzxhbcyzsfv1v8523jxlzvpsmvfhx2pz-glib-2.64.5/lib/libglib-2.0.so.0(+0x536d0) [0x7fc520a4f6d0]
0000056  /nix/store/fzxhbcyzsfv1v8523jxlzvpsmvfhx2pz-glib-2.64.5/lib/libglib-2.0.so.0(g_main_context_iteration+0x2f) [0x7fc520a4f75f]
0000057  0x7fc5240fa6be in QEventDispatcherGlib::processEvents(QFlags<QEventLoop::ProcessEventsFlag>) from /nix/store/m1bvfyy6m7j3r75x72npprnmqvm7ql2a-qtbase-5.15.0/lib/libQt5Core.so.5+0x5e
0000058  0x7fc5240a038b in QEventLoop::exec(QFlags<QEventLoop::ProcessEventsFlag>) from /nix/store/m1bvfyy6m7j3r75x72npprnmqvm7ql2a-qtbase-5.15.0/lib/libQt5Core.so.5+0x12b
0000059  0x7fc5240a85f0 in QCoreApplication::exec() from /nix/store/m1bvfyy6m7j3r75x72npprnmqvm7ql2a-qtbase-5.15.0/lib/libQt5Core.so.5+0x90
0000060  0x7fc52726cad1 in Gui::Application::runApplication() from /nix/store/knmz55iw0kq4k1y0dpsvvzgzr4x1bak5-freecad-unstable-2020-09-25/lib/libFreeCADGui.so+0x1861
0000061  /nix/store/knmz55iw0kq4k1y0dpsvvzgzr4x1bak5-freecad-unstable-2020-09-25/bin/FreeCAD() [0x4058e0]
0000062  /nix/store/33idnvrkvfgd5lsx2pwgwwi955adl6sk-glibc-2.31/lib/libc.so.6(__libc_start_main+0xed) [0x7fc523812c7d]
0000063  /nix/store/knmz55iw0kq4k1y0dpsvvzgzr4x1bak5-freecad-unstable-2020-09-25/bin/FreeCAD() [0x405bea]
Tagscrash
FreeCAD InformationOS: NixOS 20.09 (Nightingale) (none+i3/none+i3)
Word size of OS: 64-bit
Word size of FreeCAD: 64-bit
Version: 0.19.Unknown
Build type: Release
Python version: 3.8.5
Qt version: 5.15.0
Coin version: 4.0.0
OCC version: 7.3.0
Locale: English/United States (en_US)

Activities

robryk

2020-12-25 18:22

reporter  

repro1.FCStd (5,668 bytes)

chennes

2021-01-02 02:14

developer   ~0015195

I could not reproduce on a fresh compile of HEAD (either following your steps from the beginning, or loading your file and starting from there). Abdullah has been doing a ton of work on Sketcher recently, so it may be that the underlying cause here has been fixed already. I'm currently testing on:
OS: Windows 10 Version 2004
Word size of OS: 64-bit
Word size of FreeCAD: 64-bit
Version: 0.19.23574 (Git)
Build type: Debug
Branch: master
Hash: 01072f370965f9f3cb5774ffcb60511fc4d4a88b
Python version: 3.8.6+
Qt version: 5.15.1
Coin version: 4.0.1
OCC version: 7.5.0
Locale: English/United States (en_US)

Issue History

Date Modified Username Field Change
2020-12-25 18:22 robryk New Issue
2020-12-25 18:22 robryk Tag Attached: crash
2020-12-25 18:22 robryk File Added: repro1.FCStd
2021-01-02 02:14 chennes Note Added: 0015195
2021-02-06 06:43 abdullah Target Version => 0.20