ubuntu - Core dump with PyQt4 -


i starting pyqt4 , facing coredump when using qgraphicsscene/view in easiest of examples:

#!/usr/bin/python  import sys pyqt4.qtcore import * pyqt4.qtgui import *  app = qapplication(sys.argv)  grview = qgraphicsview() scene = qgraphicsscene() grview.setscene(scene)  grview.show()  sys.exit(app.exec_()) 

the program runs, when closing it gives tons of gtk errors (using ubuntu) , core dump (segmentation fault):

(python:2732): gtk-critical **: ia__gtk_container_add: assertion `gtk_is_container (container)' failed  (python:2732): gtk-critical **: ia__gtk_widget_realize: assertion `gtk_widget_anchored (widget) || gtk_is_invisible (widget)' failed  (python:2732): gtk-critical **: ia__gtk_widget_realize: assertion `gtk_widget_anchored (widget) || gtk_is_invisible (widget)' failed  (python:2732): gtk-critical **: ia__gtk_container_add: assertion `gtk_is_container (container)' failed  (python:2732): gtk-critical **: ia__gtk_widget_realize: assertion `gtk_widget_anchored (widget) || gtk_is_invisible (widget)' failed  (python:2732): gtk-critical **: ia__gtk_widget_realize: assertion `gtk_widget_anchored (widget) || gtk_is_invisible (widget)' failed  (python:2732): gtk-critical **: ia__gtk_widget_realize: assertion `gtk_widget_anchored (widget) || gtk_is_invisible (widget)' failed  (python:2732): gtk-critical **: ia__gtk_widget_realize: assertion `gtk_widget_anchored (widget) || gtk_is_invisible (widget)' failed  (python:2732): gtk-critical **: ia__gtk_container_add: assertion `gtk_is_container (container)' failed  (python:2732): gtk-critical **: ia__gtk_widget_realize: assertion `gtk_widget_anchored (widget) || gtk_is_invisible (widget)' failed  (python:2732): gtk-critical **: ia__gtk_widget_realize: assertion `gtk_widget_anchored (widget) || gtk_is_invisible (widget)' failed  (python:2732): gtk-critical **: ia__gtk_container_add: assertion `gtk_is_container (container)' failed  (python:2732): gtk-critical **: ia__gtk_widget_realize: assertion `gtk_widget_anchored (widget) || gtk_is_invisible (widget)' failed  (python:2732): gtk-critical **: ia__gtk_widget_realize: assertion `gtk_widget_anchored (widget) || gtk_is_invisible (widget)' failed  (python:2732): gtk-critical **: ia__gtk_container_add: assertion `gtk_is_container (container)' failed  (python:2732): gtk-critical **: ia__gtk_widget_realize: assertion `gtk_widget_anchored (widget) || gtk_is_invisible (widget)' failed  (python:2732): gtk-critical **: ia__gtk_widget_realize: assertion `gtk_widget_anchored (widget) || gtk_is_invisible (widget)' failed  (python:2732): gtk-critical **: ia__gtk_container_add: assertion `gtk_is_container (container)' failed  (python:2732): gtk-critical **: ia__gtk_widget_realize: assertion `gtk_widget_anchored (widget) || gtk_is_invisible (widget)' failed  (python:2732): gtk-critical **: ia__gtk_widget_realize: assertion `gtk_widget_anchored (widget) || gtk_is_invisible (widget)' failed  (python:2732): gtk-critical **: ia__gtk_container_add: assertion `gtk_is_container (container)' failed  (python:2732): gtk-critical **: ia__gtk_widget_realize: assertion `gtk_widget_anchored (widget) || gtk_is_invisible (widget)' failed  (python:2732): gtk-critical **: ia__gtk_widget_realize: assertion `gtk_widget_anchored (widget) || gtk_is_invisible (widget)' failed  (python:2732): gtk-critical **: ia__gtk_widget_realize: assertion `gtk_widget_anchored (widget) || gtk_is_invisible (widget)' failed  (python:2732): gtk-critical **: ia__gtk_widget_realize: assertion `gtk_widget_anchored (widget) || gtk_is_invisible (widget)' failed  (python:2732): gtk-critical **: ia__gtk_widget_realize: assertion `gtk_widget_anchored (widget) || gtk_is_invisible (widget)' failed  (python:2732): gtk-critical **: ia__gtk_widget_realize: assertion `gtk_widget_anchored (widget) || gtk_is_invisible (widget)' failed  (python:2732): gtk-critical **: ia__gtk_widget_realize: assertion `gtk_widget_anchored (widget) || gtk_is_invisible (widget)' failed  (python:2732): gtk-critical **: ia__gtk_container_add: assertion `gtk_is_container (container)' failed  (python:2732): gtk-critical **: ia__gtk_widget_realize: assertion `gtk_widget_anchored (widget) || gtk_is_invisible (widget)' failed  (python:2732): gtk-critical **: ia__gtk_widget_realize: assertion `gtk_widget_anchored (widget) || gtk_is_invisible (widget)' failed  (python:2732): gtk-critical **: ia__gtk_widget_realize: assertion `gtk_widget_anchored (widget) || gtk_is_invisible (widget)' failed  (python:2732): gtk-critical **: ia__gtk_widget_realize: assertion `gtk_widget_anchored (widget) || gtk_is_invisible (widget)' failed  (python:2732): gtk-critical **: ia__gtk_widget_realize: assertion `gtk_widget_anchored (widget) || gtk_is_invisible (widget)' failed  (python:2732): gtk-critical **: ia__gtk_widget_realize: assertion `gtk_widget_anchored (widget) || gtk_is_invisible (widget)' failed  (python:2732): gtk-critical **: ia__gtk_container_add: assertion `gtk_is_container (container)' failed  (python:2732): gtk-critical **: ia__gtk_widget_realize: assertion `gtk_widget_anchored (widget) || gtk_is_invisible (widget)' failed  (python:2732): gtk-critical **: ia__gtk_widget_realize: assertion `gtk_widget_anchored (widget) || gtk_is_invisible (widget)' failed  (python:2732): gtk-critical **: ia__gtk_container_add: assertion `gtk_is_container (container)' failed  (python:2732): gtk-critical **: ia__gtk_widget_realize: assertion `gtk_widget_anchored (widget) || gtk_is_invisible (widget)' failed  (python:2732): gtk-critical **: ia__gtk_widget_realize: assertion `gtk_widget_anchored (widget) || gtk_is_invisible (widget)' failed  (python:2732): gtk-critical **: ia__gtk_container_add: assertion `gtk_is_container (container)' failed  (python:2732): gtk-critical **: ia__gtk_widget_realize: assertion `gtk_widget_anchored (widget) || gtk_is_invisible (widget)' failed  (python:2732): gtk-critical **: ia__gtk_widget_realize: assertion `gtk_widget_anchored (widget) || gtk_is_invisible (widget)' failed  (python:2732): gtk-critical **: ia__gtk_widget_realize: assertion `gtk_widget_anchored (widget) || gtk_is_invisible (widget)' failed  (python:2732): gtk-critical **: ia__gtk_container_add: assertion `gtk_is_container (container)' failed  (python:2732): gtk-critical **: ia__gtk_widget_realize: assertion `gtk_widget_anchored (widget) || gtk_is_invisible (widget)' failed  (python:2732): gtk-critical **: ia__gtk_widget_realize: assertion `gtk_widget_anchored (widget) || gtk_is_invisible (widget)' failed  (python:2732): gtk-critical **: ia__gtk_widget_realize: assertion `gtk_widget_anchored (widget) || gtk_is_invisible (widget)' failed  (python:2732): gtk-critical **: ia__gtk_widget_realize: assertion `gtk_widget_anchored (widget) || gtk_is_invisible (widget)' failed  (python:2732): gtk-critical **: ia__gtk_widget_realize: assertion `gtk_widget_anchored (widget) || gtk_is_invisible (widget)' failed  (python:2732): gtk-critical **: ia__gtk_container_add: assertion `gtk_is_container (container)' failed  (python:2732): gtk-critical **: ia__gtk_widget_realize: assertion `gtk_widget_anchored (widget) || gtk_is_invisible (widget)' failed  (python:2732): gtk-critical **: ia__gtk_widget_realize: assertion `gtk_widget_anchored (widget) || gtk_is_invisible (widget)' failed  (python:2732): gtk-critical **: ia__gtk_container_add: assertion `gtk_is_container (container)' failed  (python:2732): gtk-critical **: ia__gtk_widget_realize: assertion `gtk_widget_anchored (widget) || gtk_is_invisible (widget)' failed  (python:2732): gtk-critical **: ia__gtk_widget_realize: assertion `gtk_widget_anchored (widget) || gtk_is_invisible (widget)' failed  (python:2732): gtk-critical **: ia__gtk_container_add: assertion `gtk_is_container (container)' failed  (python:2732): gtk-critical **: ia__gtk_widget_realize: assertion `gtk_widget_anchored (widget) || gtk_is_invisible (widget)' failed  (python:2732): gtk-critical **: ia__gtk_widget_realize: assertion `gtk_widget_anchored (widget) || gtk_is_invisible (widget)' failed  (python:2732): gtk-critical **: ia__gtk_widget_realize: assertion `gtk_widget_anchored (widget) || gtk_is_invisible (widget)' failed  (python:2732): gtk-critical **: ia__gtk_widget_realize: assertion `gtk_widget_anchored (widget) || gtk_is_invisible (widget)' failed  (python:2732): gtk-critical **: ia__gtk_container_add: assertion `gtk_is_container (container)' failed  (python:2732): gtk-critical **: ia__gtk_widget_realize: assertion `gtk_widget_anchored (widget) || gtk_is_invisible (widget)' failed  (python:2732): gtk-critical **: ia__gtk_widget_realize: assertion `gtk_widget_anchored (widget) || gtk_is_invisible (widget)' failed  (python:2732): gtk-critical **: ia__gtk_widget_realize: assertion `gtk_widget_anchored (widget) || gtk_is_invisible (widget)' failed  (python:2732): gtk-critical **: ia__gtk_widget_realize: assertion `gtk_widget_anchored (widget) || gtk_is_invisible (widget)' failed  (python:2732): gtk-critical **: ia__gtk_widget_realize: assertion `gtk_widget_anchored (widget) || gtk_is_invisible (widget)' failed  (python:2732): gtk-critical **: ia__gtk_container_add: assertion `gtk_is_container (container)' failed  (python:2732): gtk-critical **: ia__gtk_widget_realize: assertion `gtk_widget_anchored (widget) || gtk_is_invisible (widget)' failed  (python:2732): gtk-critical **: ia__gtk_widget_realize: assertion `gtk_widget_anchored (widget) || gtk_is_invisible (widget)' failed  (python:2732): gtk-critical **: ia__gtk_container_add: assertion `gtk_is_container (container)' failed  (python:2732): gtk-critical **: ia__gtk_widget_realize: assertion `gtk_widget_anchored (widget) || gtk_is_invisible (widget)' failed  (python:2732): gtk-critical **: ia__gtk_widget_realize: assertion `gtk_widget_anchored (widget) || gtk_is_invisible (widget)' failed  (python:2732): gtk-critical **: ia__gtk_container_add: assertion `gtk_is_container (container)' failed  (python:2732): gtk-critical **: ia__gtk_widget_realize: assertion `gtk_widget_anchored (widget) || gtk_is_invisible (widget)' failed  (python:2732): gtk-critical **: ia__gtk_widget_realize: assertion `gtk_widget_anchored (widget) || gtk_is_invisible (widget)' failed  (python:2732): gtk-critical **: ia__gtk_container_add: assertion `gtk_is_container (container)' failed  (python:2732): gtk-critical **: ia__gtk_widget_realize: assertion `gtk_widget_anchored (widget) || gtk_is_invisible (widget)' failed  (python:2732): gtk-critical **: ia__gtk_widget_realize: assertion `gtk_widget_anchored (widget) || gtk_is_invisible (widget)' failed  (python:2732): gtk-critical **: ia__gtk_widget_realize: assertion `gtk_widget_anchored (widget) || gtk_is_invisible (widget)' failed  (python:2732): gtk-critical **: ia__gtk_widget_realize: assertion `gtk_widget_anchored (widget) || gtk_is_invisible (widget)' failed  (python:2732): gtk-critical **: ia__gtk_widget_realize: assertion `gtk_widget_anchored (widget) || gtk_is_invisible (widget)' failed  (python:2732): gtk-critical **: ia__gtk_container_add: assertion `gtk_is_container (container)' failed  (python:2732): gtk-critical **: ia__gtk_widget_realize: assertion `gtk_widget_anchored (widget) || gtk_is_invisible (widget)' failed  (python:2732): gtk-critical **: ia__gtk_widget_realize: assertion `gtk_widget_anchored (widget) || gtk_is_invisible (widget)' failed  (python:2732): gtk-critical **: ia__gtk_widget_realize: assertion `gtk_widget_anchored (widget) || gtk_is_invisible (widget)' failed  (python:2732): gtk-critical **: ia__gtk_widget_realize: assertion `gtk_widget_anchored (widget) || gtk_is_invisible (widget)' failed  (python:2732): gtk-critical **: ia__gtk_widget_realize: assertion `gtk_widget_anchored (widget) || gtk_is_invisible (widget)' failed  (python:2732): gtk-critical **: ia__gtk_widget_realize: assertion `gtk_widget_anchored (widget) || gtk_is_invisible (widget)' failed  (python:2732): gtk-critical **: ia__gtk_widget_realize: assertion `gtk_widget_anchored (widget) || gtk_is_invisible (widget)' failed  (python:2732): gtk-critical **: ia__gtk_widget_realize: assertion `gtk_widget_anchored (widget) || gtk_is_invisible (widget)' failed  (python:2732): gtk-critical **: ia__gtk_widget_realize: assertion `gtk_widget_anchored (widget) || gtk_is_invisible (widget)' failed  (python:2732): gtk-critical **: ia__gtk_widget_realize: assertion `gtk_widget_anchored (widget) || gtk_is_invisible (widget)' failed  (python:2732): gtk-critical **: ia__gtk_widget_realize: assertion `gtk_widget_anchored (widget) || gtk_is_invisible (widget)' failed  (python:2732): gtk-critical **: ia__gtk_widget_realize: assertion `gtk_widget_anchored (widget) || gtk_is_invisible (widget)' failed  (python:2732): gtk-critical **: ia__gtk_widget_realize: assertion `gtk_widget_anchored (widget) || gtk_is_invisible (widget)' failed  (python:2732): gtk-critical **: ia__gtk_widget_realize: assertion `gtk_widget_anchored (widget) || gtk_is_invisible (widget)' failed  (python:2732): gtk-critical **: ia__gtk_widget_realize: assertion `gtk_widget_anchored (widget) || gtk_is_invisible (widget)' failed  (python:2732): gtk-critical **: ia__gtk_widget_realize: assertion `gtk_widget_anchored (widget) || gtk_is_invisible (widget)' failed  (python:2732): gtk-critical **: ia__gtk_widget_realize: assertion `gtk_widget_anchored (widget) || gtk_is_invisible (widget)' failed  (python:2732): gtk-critical **: ia__gtk_container_add: assertion `gtk_is_container (container)' failed  (python:2732): gtk-critical **: ia__gtk_widget_realize: assertion `gtk_widget_anchored (widget) || gtk_is_invisible (widget)' failed  (python:2732): gtk-critical **: ia__gtk_widget_realize: assertion `gtk_widget_anchored (widget) || gtk_is_invisible (widget)' failed  (python:2732): gtk-critical **: ia__gtk_container_add: assertion `gtk_is_container (container)' failed  (python:2732): gtk-critical **: ia__gtk_widget_realize: assertion `gtk_widget_anchored (widget) || gtk_is_invisible (widget)' failed  (python:2732): gtk-critical **: ia__gtk_widget_realize: assertion `gtk_widget_anchored (widget) || gtk_is_invisible (widget)' failed violaciĆ³n de segmento (`core' generado) 

i assume has linux setup. faced before?

thanks!

the gtk errors unrelated segfault. i'm using kde (and therefore not gtk theme), don't see gtk errors, segfault.

the segfault happens in destructor of qgraphicsscene:

#0  0x00007ffff6f09037 in raise () /lib/x86_64-linux-gnu/libc.so.6 #1  0x00007ffff6f0c698 in abort () /lib/x86_64-linux-gnu/libc.so.6 #2  0x00007ffff5b465c2 in qt_message_output(qtmsgtype, char const*) () /usr/lib/x86_64-linux-gnu/libqtcore.so.4 #3  0x00007ffff5b46938 in ?? () /usr/lib/x86_64-linux-gnu/libqtcore.so.4 #4  0x00007ffff5b46ac4 in qfatal(char const*, ...) () /usr/lib/x86_64-linux-gnu/libqtcore.so.4 #5  0x00007ffff389231e in ?? () /usr/lib/x86_64-linux-gnu/libqtgui.so.4 #6  0x00007ffff3893401 in qpixmap::qpixmap() () /usr/lib/x86_64-linux-gnu/libqtgui.so.4 #7  0x00007fffea0a8c86 in oxygen::helper::helper(qbytearray const&) () /usr/lib/liboxygenstyle.so.4 #8  0x00007fffea3450e0 in ?? () /usr/lib/kde4/plugins/styles/oxygen.so #9  0x00007fffea32f757 in ?? () /usr/lib/kde4/plugins/styles/oxygen.so #10 0x00007fffea33c7bc in ?? () /usr/lib/kde4/plugins/styles/oxygen.so #11 0x00007ffff3ab64e6 in qstylefactory::create(qstring const&) () /usr/lib/x86_64-linux-gnu/libqtgui.so.4 #12 0x00007ffff37c74cf in qapplication::style() () /usr/lib/x86_64-linux-gnu/libqtgui.so.4 #13 0x00007ffff37fe488 in qwidget::isactivewindow() const () /usr/lib/x86_64-linux-gnu/libqtgui.so.4 #14 0x00007ffff3dd5ccc in qgraphicsview::setscene(qgraphicsscene*) () /usr/lib/x86_64-linux-gnu/libqtgui.so.4 #15 0x00007ffff3da47d1 in qgraphicsscene::~qgraphicsscene() () /usr/lib/x86_64-linux-gnu/libqtgui.so.4 #16 0x00007ffff46b6bb9 in ?? () /usr/lib/python2.7/dist-packages/pyqt4/qtgui.so #17 0x00007ffff46b4ad6 in ?? () /usr/lib/python2.7/dist-packages/pyqt4/qtgui.so #18 0x00007ffff4c6115e in ?? () /usr/lib/python2.7/dist-packages/sip.so #19 0x00007ffff4c62aa9 in ?? () /usr/lib/python2.7/dist-packages/sip.so #20 0x00000000004af4f0 in ?? () #21 0x00000000004dbbc7 in ?? () #22 0x00007ffff4c6058b in ?? () /usr/lib/python2.7/dist-packages/sip.so #23 0x00007ffff4c62a22 in ?? () /usr/lib/python2.7/dist-packages/sip.so #24 0x00007ffff4c62ab1 in ?? () /usr/lib/python2.7/dist-packages/sip.so #25 0x00000000004af4f0 in ?? () #26 0x00000000004b8bca in ?? () #27 0x00000000004a4460 in pydict_setitem () #28 0x00000000004a46d7 in _pymodule_clear () #29 0x0000000000509514 in pyimport_cleanup () #30 0x0000000000423bca in py_finalize () #31 0x0000000000424470 in py_exit () #32 0x00000000004245ac in ?? () #33 0x000000000042254e in pyerr_printex () #34 0x0000000000465e0d in pyrun_simplefileexflags () #35 0x0000000000466b78 in py_main () #36 0x00007ffff6ef3ea5 in __libc_start_main () /lib/x86_64-linux-gnu/libc.so.6 #37 0x00000000004e0d95 in _start () 

making grview parent of scene should fix problem:

#!/usr/bin/python  import sys pyqt4.qtcore import * pyqt4.qtgui import *  app = qapplication(sys.argv)  grview = qgraphicsview() scene = qgraphicsscene(grview)  grview.setscene(scene)  grview.show()  sys.exit(app.exec_()) 

qobjects constructed without parent owned pyqt , not qt, error result of destructor being called twice when exiting.


Comments

Popular posts from this blog

java - Run a .jar on Heroku -

java - Jtable duplicate Rows -

validation - How to pass paramaters like unix into windows batch file -