View Issue Details

IDProjectCategoryView StatusLast Update
0001522FreeCADBugpublic2014-05-03 16:28
Reporterteobo Assigned Towmayer  
PrioritynormalSeveritycrashReproducibilityalways
Status closedResolutionfixed 
Summary0001522: SIGSEGV, crashes on long script (500 Lines)
Descriptioncrashes almost always when pasting in freecad console at once
crashes 50% when excuted from macro editor
crashes less when pasted part by part to console.
,
crashes on Windows, Mac, Ubuntu, 0.14

Workaround pause
Putting between:
import time
print("something")
time.sleep(10.5) # pause 5.5 seconds
# result crashes

cat freecad.log
FreeCAD 0.14, Libs: 0.14R3481 (Git)
© Juergen Riegel, Werner Mayer, Yorik van Havre 2001-2011
  ##### #### ### ####
  # # # # # #
  # ## #### #### # # # # #
  #### # # # # # # # ##### # #
  # # #### #### # # # # #
  # # # # # # # # # ## ## ##
  # # #### #### ### # # #### ## ## ##

Draft workbench activated
*** Abort *** an exception was raised, but no catch was found.
        ... The exception is:SIGSEGV 'segmentation violation' detected. Address 3f800060
        
        
Program received signal SIGSEGV, Segmentation fault.
0x00007ffff76e0ec7 in Gui::ViewProviderPythonFeatureObserver::customEvent(QEvent*) () from /usr/lib/freecad/lib/libFreeCADGui.so
(gdb) bt
#0 0x00007ffff76e0ec7 in Gui::ViewProviderPythonFeatureObserver::customEvent(QEvent*) () from /usr/lib/freecad/lib/libFreeCADGui.so
#1 0x00007ffff4ea3e5d in QObject::event (this=0x3a68e20, e=<optimized out>)
    at kernel/qobject.cpp:1225
0000002 0x00007ffff5600dfc in QApplicationPrivate::notify_helper (
    this=this@entry=0x762be0, receiver=receiver@entry=0x3a68e20, e=e@entry=
    0x42803a0) at kernel/qapplication.cpp:4567
0000003 0x00007ffff5607470 in QApplication::notify (this=0x7fffffffd730,
    receiver=0x3a68e20, e=0x42803a0) at kernel/qapplication.cpp:4353
0000004 0x00007ffff7442209 in Gui::GUIApplication::notify(QObject*, QEvent*) ()
   from /usr/lib/freecad/lib/libFreeCADGui.so
0000005 0x00007ffff4e8b8bd in QCoreApplication::notifyInternal (this=
    0x7fffffffd730, receiver=receiver@entry=0x3a68e20,
    event=event@entry=0x42803a0) at kernel/qcoreapplication.cpp:946
0000006 0x00007ffff4e8ee1f in sendEvent (event=0x42803a0, receiver=0x3a68e20)
    at ../../include/QtCore/../../src/corelib/kernel/qcoreapplication.h:231
0000007 QCoreApplicationPrivate::sendPostedEvents (receiver=receiver@entry=0x0,
    event_type=event_type@entry=0, data=0x6379a0)
    at kernel/qcoreapplication.cpp:1570
0000008 0x00007ffff4e8f2c3 in QCoreApplication::sendPostedEvents (
    receiver=receiver@entry=0x0, event_type=event_type@entry=0)
    at kernel/qcoreapplication.cpp:1463
0000009 0x00007ffff4eb9073 in sendPostedEvents ()
    at ../../include/QtCore/../../src/corelib/kernel/qcoreapplication.h:236
0000010 postEventSourceDispatch (s=0x763160)
    at kernel/qeventdispatcher_glib.cpp:279
0000011 0x00007fffedfcf3b6 in g_main_context_dispatch ()
   from /lib/x86_64-linux-gnu/libglib-2.0.so.0
0000012 0x00007fffedfcf708 in ?? () from /lib/x86_64-linux-gnu/libglib-2.0.so.0
0000013 0x00007fffedfcf7ac in g_main_context_iteration ()
   from /lib/x86_64-linux-gnu/libglib-2.0.so.0
0000014 0x00007ffff4eb8a55 in QEventDispatcherGlib::processEvents (this=0x762a40,
    flags=...) at kernel/qeventdispatcher_glib.cpp:424
0000015 0x00007ffff56a29d6 in QGuiEventDispatcherGlib::processEvents (
    this=<optimized out>, flags=...) at kernel/qguieventdispatcher_glib.cpp:204
0000016 0x00007ffff4e8f2ff in QCoreApplication::processEvents (flags=...)
    at kernel/qcoreapplication.cpp:1133
0000017 0x00007ffff7436ed9 in Gui::Application::slotNewDocument(App::Document const&---Type <return> to continue, or q <return> to quit---
) () from /usr/lib/freecad/lib/libFreeCADGui.so
0000018 0x00007ffff745080e in boost::_mfi::mf1<void, Gui::Application, App::Document const&>::operator()(Gui::Application*, App::Document const&) const ()
   from /usr/lib/freecad/lib/libFreeCADGui.so
0000019 0x00007ffff744fb04 in void boost::_bi::list2<boost::_bi::value<Gui::Application*>, boost::arg<1> >::operator()<boost::_mfi::mf1<void, Gui::Application, App::Document const&>, boost::_bi::list1<App::Document const&> >(boost::_bi::type<void>, boost::_mfi::mf1<void, Gui::Application, App::Document const&>&, boost::_bi::list1<App::Document const&>&, int) ()
   from /usr/lib/freecad/lib/libFreeCADGui.so
0000020 0x00007ffff744ed12 in void boost::_bi::bind_t<void, boost::_mfi::mf1<void, Gui::Application, App::Document const&>, boost::_bi::list2<boost::_bi::value<Gui::Application*>, boost::arg<1> > >::operator()<App::Document>(App::Document const&) () from /usr/lib/freecad/lib/libFreeCADGui.so
0000021 0x00007ffff744d704 in boost::detail::function::void_function_obj_invoker1<boost::_bi::bind_t<void, boost::_mfi::mf1<void, Gui::Application, App::Document const&>, boost::_bi::list2<boost::_bi::value<Gui::Application*>, boost::arg<1> > >, void, App::Document const&>::invoke(boost::detail::function::function_buffer&, App::Document const&) () from /usr/lib/freecad/lib/libFreeCADGui.so
0000022 0x00007ffff6c58b25 in boost::function1<void, App::Document const&>::operator()(App::Document const&) const () from /usr/lib/freecad/lib/libFreeCADApp.so
0000023 0x00007ffff6c55a5a in boost::signals::detail::unusable boost::signals::detail::call_bound1<void>::caller<App::Document const&, boost::function<void (App::Document const&)> >::operator()<boost::signals::detail::connection_slot_pair>(boost::signals::detail::connection_slot_pair const&) const ()
   from /usr/lib/freecad/lib/libFreeCADApp.so
0000024 0x00007ffff6c524f8 in boost::signals::detail::slot_call_iterator<boost::signals::detail::call_bound1<void>::caller<App::Document const&, boost::function<void (App::Document const&)> >, boost::signals::detail::named_slot_map_iterator>::dereference() const () from /usr/lib/freecad/lib/libFreeCADApp.so
0000025 0x00007ffff6c4efdc in boost::signals::detail::slot_call_iterator<boost::signals::detail::call_bound1<void>::caller<App::Document const&, boost::function<void (App::Document const&)> >, boost::signals::detail::named_slot_map_iterator>::reference boost::iterator_core_access::dereference<boost::signals::detail::slot_call_iterator<boost::signals::detail::call_bound1<void>::caller<App::Document const&, boost::function<void (App::Document const&)> >, boost::signals::detail::named_slot_map_iterator> >(boost::signals::detail::slot_call_iterator<boost::signals::detail::call_bound1<void>::caller<App::Document const&, boost::function<void ---Type <return> to continue, or q <return> to quit---
(App::Document const&)> >, boost::signals::detail::named_slot_map_iterator> const&) () from /usr/lib/freecad/lib/libFreeCADApp.so
0000026 0x00007ffff6c4b190 in boost::iterator_facade<boost::signals::detail::slot_call_iterator<boost::signals::detail::call_bound1<void>::caller<App::Document const&, boost::function<void (App::Document const&)> >, boost::signals::detail::named_slot_map_iterator>, boost::signals::detail::unusable, boost::single_pass_traversal_tag, boost::signals::detail::unusable const&, long>::operator*() const ()
   from /usr/lib/freecad/lib/libFreeCADApp.so
0000027 0x00007ffff6c4680e in boost::detail::postfix_increment_proxy<boost::signals::detail::slot_call_iterator<boost::signals::detail::call_bound1<void>::caller<App::Document const&, boost::function<void (App::Document const&)> >, boost::signals::detail::named_slot_map_iterator> >::postfix_increment_proxy(boost::signals::detail::slot_call_iterator<boost::signals::detail::call_bound1<void>::caller<App::Document const&, boost::function<void (App::Document const&)> >, boost::signals::detail::named_slot_map_iterator> const&) ()
   from /usr/lib/freecad/lib/libFreeCADApp.so
0000028 0x00007ffff6c40856 in boost::detail::postfix_increment_result<boost::signals::detail::slot_call_iterator<boost::signals::detail::call_bound1<void>::caller<App::Document const&, boost::function<void (App::Document const&)> >, boost::signals::detail::named_slot_map_iterator>, boost::signals::detail::unusable, boost::signals::detail::unusable const&, boost::single_pass_traversal_tag>::type boost::operator++<boost::signals::detail::slot_call_iterator<boost::signals::detail::call_bound1<void>::caller<App::Document const&, boost::function<void (App::Document const&)> >, boost::signals::detail::named_slot_map_iterator>, boost::signals::detail::unusable, boost::single_pass_traversal_tag, boost::signals::detail::unusable const&, long>(boost::iterator_facade<boost::signals::detail::slot_call_iterator<boost::signals::detail::call_bound1<void>::caller<App::Document const&, boost::function<void (App::Document const&)> >, boost::signals::detail::named_slot_map_iterator>, boost::signals::detail::unusable, boost::single_pass_traversal_tag, boost::signals::detail::unusable const&, long>&, int) ()
   from /usr/lib/freecad/lib/libFreeCADApp.so
0000029 0x00007ffff6c3af75 in void boost::last_value<void>::operator()<boost::signals::detail::slot_call_iterator<boost::signals::detail::call_bound1<void>::caller<App::Document const&, boost::function<void (App::Document const&)> >, boost::signals::detail::named_slot_map_iterator> >(boost::signals::detail::slot_call_iterator<boost::signals::detail::call_bound1<void>::caller<App::Document const&, boost::function<void (App::Document const&)> >, boost::signals::detail::named_slot_map_iterator>, boost::signals::detail::slot_call_iterator<boost::signals::detail:---Type <return> to continue, or q <return> to quit---
:call_bound1<void>::caller<App::Document const&, boost::function<void (App::Document const&)> >, boost::signals::detail::named_slot_map_iterator>) const ()
   from /usr/lib/freecad/lib/libFreeCADApp.so
0000030 0x00007ffff6c368a6 in boost::signal1<void, App::Document const&, boost::last_value<void>, int, std::less<int>, boost::function<void (App::Document const&)> >::operator()(App::Document const&) ()
   from /usr/lib/freecad/lib/libFreeCADApp.so
0000031 0x00007ffff6cdd0d6 in App::Application::newDocument(char const*, char const*) () from /usr/lib/freecad/lib/libFreeCADApp.so
0000032 0x00007ffff6cfe540 in App::Application::sNewDocument(_object*, _object*, _object*) () from /usr/lib/freecad/lib/libFreeCADApp.so
0000033 0x00007ffff6228ad4 in PyEval_EvalFrameEx ()
   from /usr/lib/x86_64-linux-gnu/libpython2.7.so.1.0
0000034 0x00007ffff622ab4d in PyEval_EvalCodeEx ()
   from /usr/lib/x86_64-linux-gnu/libpython2.7.so.1.0
0000035 0x00007ffff622ae32 in PyEval_EvalCode ()
   from /usr/lib/x86_64-linux-gnu/libpython2.7.so.1.0
0000036 0x00007ffff75d3656 in Gui::InteractiveInterpreter::runCode(PyCodeObject*) const () from /usr/lib/freecad/lib/libFreeCADGui.so
0000037 0x00007ffff75d34e2 in Gui::InteractiveInterpreter::runSource(char const*) const () from /usr/lib/freecad/lib/libFreeCADGui.so
0000038 0x00007ffff75d3870 in Gui::InteractiveInterpreter::push(char const*) ()
   from /usr/lib/freecad/lib/libFreeCADGui.so
#39 0x00007ffff75d596a in Gui::PythonConsole::runSource(QString const&) ()
   from /usr/lib/freecad/lib/libFreeCADGui.so
#40 0x00007ffff75d7e52 in Gui::PythonConsole::runSourceFromMimeData(QString const&) () from /usr/lib/freecad/lib/libFreeCADGui.so
0000041 0x00007ffff75d71b3 in Gui::PythonConsole::insertFromMimeData(QMimeData const*) () from /usr/lib/freecad/lib/libFreeCADGui.so
0000042 0x00007ffff4e9fa58 in QMetaObject::activate (
    sender=sender@entry=0x1c11700,
    m=m@entry=0x7ffff60a9de0 <QAction::staticMetaObject>,
    local_signal_index=local_signal_index@entry=1,
    argv=argv@entry=0x7fffffffb520) at kernel/qobject.cpp:3539
0000043 0x00007ffff55faa32 in QAction::triggered (this=this@entry=0x1c11700,
    _t1=false) at .moc/release-shared/moc_qaction.cpp:277
0000044 0x00007ffff55fc403 in QAction::activate (this=this@entry=0x1c11700,
    event=event@entry=QAction::Trigger) at kernel/qaction.cpp:1257
---Type <return> to continue, or q <return> to quit---
0000045 0x00007ffff5a297f9 in QMenuPrivate::activateCausedStack (
    this=this@entry=0x1d47e70, causedStack=..., action=action@entry=0x1c11700,
    action_e=action_e@entry=QAction::Trigger, self=self@entry=true)
    at widgets/qmenu.cpp:1038
0000046 0x00007ffff5a2dd19 in QMenuPrivate::activateAction (this=0x1d47e70,
    action=0x1c11700, action_e=QAction::Trigger, self=<optimized out>)
    at widgets/qmenu.cpp:1130
0000047 0x00007ffff565031e in QWidget::event (this=this@entry=0x7fffffffc630,
    event=event@entry=0x7fffffffbd20) at kernel/qwidget.cpp:8375
0000048 0x00007ffff5a31aeb in QMenu::event (this=0x7fffffffc630, e=0x7fffffffbd20)
    at widgets/qmenu.cpp:2481
0000049 0x00007ffff5600dfc in QApplicationPrivate::notify_helper (
    this=this@entry=0x762be0, receiver=receiver@entry=0x7fffffffc630,
    e=e@entry=0x7fffffffbd20) at kernel/qapplication.cpp:4567
0000050 0x00007ffff56075ad in QApplication::notify (this=<optimized out>,
    receiver=0x7fffffffc630, e=0x7fffffffbd20) at kernel/qapplication.cpp:4110
0000051 0x00007ffff7442209 in Gui::GUIApplication::notify(QObject*, QEvent*) ()
   from /usr/lib/freecad/lib/libFreeCADGui.so
0000052 0x00007ffff4e8b8bd in QCoreApplication::notifyInternal (
    this=0x7fffffffd730, receiver=receiver@entry=0x7fffffffc630,
    event=event@entry=0x7fffffffbd20) at kernel/qcoreapplication.cpp:946
0000053 0x00007ffff5606d63 in sendEvent (event=<optimized out>,
    receiver=<optimized out>)
    at ../../include/QtCore/../../src/corelib/kernel/qcoreapplication.h:231
0000054 QApplicationPrivate::sendMouseEvent (
    receiver=receiver@entry=0x7fffffffc630, event=event@entry=0x7fffffffbd20,
    alienWidget=alienWidget@entry=0x0,
    nativeWidget=nativeWidget@entry=0x7fffffffc630,
    buttonDown=buttonDown@entry=0x7ffff60e52f8 <qt_button_down>,
    lastMouseReceiver=..., spontaneous=spontaneous@entry=true)
    at kernel/qapplication.cpp:3178
0000055 0x00007ffff567bb0c in QETWidget::translateMouseEvent (
    this=this@entry=0x7fffffffc630, event=event@entry=0x7fffffffc070)
    at kernel/qapplication_x11.cpp:4565
0000056 0x00007ffff567b079 in QApplication::x11ProcessEvent (this=0x7fffffffd730,
    event=event@entry=0x7fffffffc070) at kernel/qapplication_x11.cpp:3624
0000057 0x00007ffff56a2922 in x11EventSourceDispatch (s=0x7d7350, callback=0x0,
    user_data=0x0) at kernel/qguieventdispatcher_glib.cpp:146
---Type <return> to continue, or q <return> to quit---
0000058 0x00007fffedfcf3b6 in g_main_context_dispatch ()
   from /lib/x86_64-linux-gnu/libglib-2.0.so.0
0000059 0x00007fffedfcf708 in ?? () from /lib/x86_64-linux-gnu/libglib-2.0.so.0
0000060 0x00007fffedfcf7ac in g_main_context_iteration ()
   from /lib/x86_64-linux-gnu/libglib-2.0.so.0
0000061 0x00007ffff4eb8a55 in QEventDispatcherGlib::processEvents (this=0x762a40,
    flags=...) at kernel/qeventdispatcher_glib.cpp:424
0000062 0x00007ffff56a29d6 in QGuiEventDispatcherGlib::processEvents (
    this=<optimized out>, flags=...) at kernel/qguieventdispatcher_glib.cpp:204
0000063 0x00007ffff4e8a5ef in QEventLoop::processEvents (this=this@entry=
    0x7fffffffc460, flags=...) at kernel/qeventloop.cpp:149
0000064 0x00007ffff4e8a8e5 in QEventLoop::exec (this=this@entry=0x7fffffffc460,
    flags=...) at kernel/qeventloop.cpp:204
0000065 0x00007ffff5a308e7 in QMenu::exec (this=0x7fffffffc630, p=..., action=0x0)
    at widgets/qmenu.cpp:2125
0000066 0x00007ffff75d8ae3 in Gui::PythonConsole::contextMenuEvent(QContextMenuEvent*) () from /usr/lib/freecad/lib/libFreeCADGui.so
0000067 0x00007ffff56505e2 in QWidget::event (this=this@entry=0xbafe60,
    event=event@entry=0x7fffffffcc50) at kernel/qwidget.cpp:8553
0000068 0x00007ffff59f15be in QFrame::event (this=0xbafe60, e=0x7fffffffcc50)
    at widgets/qframe.cpp:557
0000069 0x00007ffff4e8ba26 in QCoreApplicationPrivate::sendThroughObjectEventFilters (this=this@entry=0x762be0, receiver=receiver@entry=0xbb0110,
    event=event@entry=0x7fffffffcc50) at kernel/qcoreapplication.cpp:1056
0000070 0x00007ffff5600ddc in QApplicationPrivate::notify_helper (
    this=this@entry=0x762be0, receiver=receiver@entry=0xbb0110,
    e=e@entry=0x7fffffffcc50) at kernel/qapplication.cpp:4563
0000071 0x00007ffff56081d0 in QApplication::notify (this=<optimized out>,
    receiver=0xbb0110, e=0x7fffffffcc50) at kernel/qapplication.cpp:4189
0000072 0x00007ffff7442209 in Gui::GUIApplication::notify(QObject*, QEvent*) ()
   from /usr/lib/freecad/lib/libFreeCADGui.so
0000073 0x00007ffff4e8b8bd in QCoreApplication::notifyInternal (
    this=0x7fffffffd730, receiver=receiver@entry=0xbb0110,
    event=event@entry=0x7fffffffcc50) at kernel/qcoreapplication.cpp:946
0000074 0x00007ffff567b830 in sendSpontaneousEvent (event=0x7fffffffcc50,
    receiver=0xbb0110)
    at ../../include/QtCore/../../src/corelib/kernel/qcoreapplication.h:234
0000075 QETWidget::translateMouseEvent (this=this@entry=0xbb0110,
---Type <return> to continue, or q <return> to quit---
    event=event@entry=0x7fffffffcfa0) at kernel/qapplication_x11.cpp:4636
0000076 0x00007ffff567b079 in QApplication::x11ProcessEvent (this=0x7fffffffd730,
    event=event@entry=0x7fffffffcfa0) at kernel/qapplication_x11.cpp:3624
0000077 0x00007ffff56a2922 in x11EventSourceDispatch (s=0x7d7350, callback=0x0,
    user_data=0x0) at kernel/qguieventdispatcher_glib.cpp:146
0000078 0x00007fffedfcf3b6 in g_main_context_dispatch ()
   from /lib/x86_64-linux-gnu/libglib-2.0.so.0
0000079 0x00007fffedfcf708 in ?? () from /lib/x86_64-linux-gnu/libglib-2.0.so.0
0000080 0x00007fffedfcf7ac in g_main_context_iteration ()
   from /lib/x86_64-linux-gnu/libglib-2.0.so.0
0000081 0x00007ffff4eb8a55 in QEventDispatcherGlib::processEvents (this=0x762a40,
    flags=...) at kernel/qeventdispatcher_glib.cpp:424
0000082 0x00007ffff56a29d6 in QGuiEventDispatcherGlib::processEvents (
    this=<optimized out>, flags=...) at kernel/qguieventdispatcher_glib.cpp:204
0000083 0x00007ffff4e8a5ef in QEventLoop::processEvents (
    this=this@entry=0x7fffffffd380, flags=...) at kernel/qeventloop.cpp:149
0000084 0x00007ffff4e8a8e5 in QEventLoop::exec (this=this@entry=0x7fffffffd380,
    flags=...) at kernel/qeventloop.cpp:204
0000085 0x00007ffff4e8fe5b in QCoreApplication::exec ()
    at kernel/qcoreapplication.cpp:1218
0000086 0x00007ffff743d54a in Gui::Application::runApplication() ()
   from /usr/lib/freecad/lib/libFreeCADGui.so
0000087 0x00000000004084d2 in main ()
Additional InformationOS: Ubuntu 13.10
Platform: 64-bit
Version: 0.14.3481 (Git)
Branch: master
Hash: 93fc937bd1422efabbd8ed8d2ad2ebe5c15d8d1d
Python version: 2.7.5+
Qt version: 4.8.4
Coin version: 4.0.0a
SoQt version: 1.5.0
TagsNo tags attached.
FreeCAD Information

Activities

wmayer

2014-04-29 12:04

administrator   ~0004594

I doubt it's related to the length of the script but to what it does. Could you share this script with us so that we can see what the problem is?

teobo

2014-05-01 21:50

reporter  

broken_140501140501.makro (Attachment missing)

teobo

2014-05-01 21:51

reporter   ~0004600

It does not crash always, but i hope pritty soon, especially after start up.

Related Changesets

FreeCAD: master c3b1c9ec

2014-05-03 17:58:57

wmayer

Details Diff
+ fixes 0001522: SIGSEGV, crashes on long script (500 Lines) Affected Issues
0001522
mod - src/Gui/ViewProviderPythonFeature.cpp Diff File

Issue History

Date Modified Username Field Change
2014-04-28 17:44 teobo New Issue
2014-04-29 12:04 wmayer Note Added: 0004594
2014-05-01 21:50 teobo File Added: broken_140501140501.makro
2014-05-01 21:51 teobo Note Added: 0004600
2014-05-03 15:18 wmayer Status new => confirmed
2014-05-03 16:28 wmayer Changeset attached => FreeCAD Master master c3b1c9ec
2014-05-03 16:28 wmayer Assigned To => wmayer
2014-05-03 16:28 wmayer Status confirmed => closed
2014-05-03 16:28 wmayer Resolution open => fixed