PySide Bugzilla Closed for New Bugs

PySide is now a Qt Add-on and uses the Qt Project's JIRA Bug Tracker instead of this Bugzilla instance. This Bugzilla is left for reference purposes.

Bug 545 - Drag & Drop Segmentation Fault
: Drag & Drop Segmentation Fault
Status: CLOSED WORKSFORME
Product: PySide
Classification: Unclassified
Component: PySide
: HEAD
: PC Linux
: P2 normal
Assigned To: Hugo Parente Lima
:
:
:
  Show dependency treegraph
 
Reported: 2010-12-14 11:56 EET by Benjamin Kloster
Modified: 2010-12-20 11:26 EET (History)
8 users (show)

See Also:


Attachments
Example script for Drag&Drop crash (1.45 KB, text/x-python)
2010-12-14 11:56 EET, Benjamin Kloster
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Benjamin Kloster 2010-12-14 11:56:20 EET
Created attachment 177 [details]
Example script for Drag&Drop crash

After starting a drag operation with QDrag.exec_(), the application crashes
when the cursor is moved twice over a QGraphicsItem that implements
dragEnterEvent.

When the QGraphicsItem keeps a local reference to the event object, the
application still crashes, but it seems to depend on how long the cursor was
outside of a drag receiver.

I have attached a minimal example. Start the script, and begin by dragging from
the big circle. When dragging over one of the smaller circles for the first
time, all is well. Enter a small circle for the second time, Segmentation
Fault.

When line 17 is commented in, the crash still happens, but only once the cursor
was outside one of the smaller circles for a few seconds.
Comment 1 Benjamin Kloster 2010-12-14 11:57:22 EET
Valgrind stack trace:


==29022== Process terminating with default action of signal 11 (SIGSEGV)
==29022==  Access not within mapped region at address 0x8
==29022==    at 0x78C12EC: std::list<Shiboken::SbkBaseWrapper*,
std::allocator<Shiboken::SbkBaseWrapper*> >::begin() (in
/usr/local/lib/libshiboken.so.0.5.1)
==29022==    by 0x78BE85A:
Shiboken::_destroyParentInfo(Shiboken::SbkBaseWrapper*, bool) (in
/usr/local/lib/libshiboken.so.0.5.1)
==29022==    by 0x78BE8EF:
Shiboken::_destroyParentInfo(Shiboken::SbkBaseWrapper*, bool) (in
/usr/local/lib/libshiboken.so.0.5.1)
==29022==    by 0x78BE9C6:
Shiboken::destroyParentInfo(Shiboken::SbkBaseWrapper*, bool) (in
/usr/local/lib/libshiboken.so.0.5.1)
==29022==    by 0x78BF7C6: Shiboken::deallocWrapper(_object*) (in
/usr/local/lib/libshiboken.so.0.5.1)
==29022==    by 0x467E2C: ??? (in /usr/bin/python2.6)
==29022==    by 0x9140786:
QGraphicsEllipseItemWrapper::dragEnterEvent(QGraphicsSceneDragDropEvent*) (in
/usr/local/lib/python2.6/dist-packages/PySide/QtGui.so)
==29022==    by 0xA49CF2C: QGraphicsItem::sceneEvent(QEvent*) (in
/usr/lib/libQtGui.so.4.7.0)
==29022==    by 0x913E59A: QGraphicsEllipseItemWrapper::sceneEvent(QEvent*) (in
/usr/local/lib/python2.6/dist-packages/PySide/QtGui.so)
==29022==    by 0xA4B24DB: ??? (in /usr/lib/libQtGui.so.4.7.0)
==29022==    by 0xA4B8C37:
QGraphicsScene::dragMoveEvent(QGraphicsSceneDragDropEvent*) (in
/usr/lib/libQtGui.so.4.7.0)
==29022==    by 0x91C343A:
QGraphicsSceneWrapper::dragMoveEvent(QGraphicsSceneDragDropEvent*) (in
/usr/local/lib/python2.6/dist-packages/PySide/QtGui.so)
Comment 2 Matti Airas 2010-12-14 13:44:22 EET
Thanks for the bug report! Since this is a crasher bug, I'm prioritizing this
P2. This will hopefully be taken care of during our next sprint, within a
couple of weeks.
Comment 3 Hugo Parente Lima 2010-12-16 15:44:41 EET
I was unable to reproduce the crash with PySide from git HEAD :-/.

What version of PySide are you using?
Comment 4 Benjamin Kloster 2010-12-17 05:58:04 EET
I think I'm using the current git version (at least I installed the packages in
my python path). But since I had to uninstall the binary packages I tried
first, I can't be absolutely certain that there's no old file floating about.

Is there a constant in the package that holds the current version? Or a
significant change from 0.5.1 to git HEAD that I can see from within the
interpreter?

In any case, my other specs:

 * Ubuntu 10.10 64-bit
 * Python 2.6.6 (installed from package manager)
 * Qt 4.7 (installed from package manager)
Comment 5 Matti Airas 2010-12-17 09:48:48 EET
(In reply to comment #4)
> I think I'm using the current git version (at least I installed the packages in
> my python path). But since I had to uninstall the binary packages I tried
> first, I can't be absolutely certain that there's no old file floating about.
> 
> Is there a constant in the package that holds the current version? Or a
> significant change from 0.5.1 to git HEAD that I can see from within the
> interpreter?

You can view the version string by checking the PySide.__version__ (PySide
version) and QtCore.__version__ (Qt version), but the information is not very
accurate - for example, for the beta releases, it says 1.0.0, and git HEAD
versions are not reported separately.
Comment 6 Hugo Parente Lima 2010-12-20 11:26:16 EET
Closign bugs after release of 1.0.0 beta2.