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 814 - PySide 1.0.1 crashes in QtDeclarative when running gPodder/QML
: PySide 1.0.1 crashes in QtDeclarative when running gPodder/QML
Status: CLOSED FIXED
Product: PySide
Classification: Unclassified
Component: QtDeclarative
: 1.0.1
: PC Linux
: P1 normal
Assigned To: Hugo Parente Lima
:
:
:
  Show dependency treegraph
 
Reported: 2011-04-06 18:50 EEST by Thomas Perl
Modified: 2011-04-29 18:06 EEST (History)
9 users (show)

See Also:


Attachments
gdb bactrace, obtained using "gdb --args python bin/gpodder --qml" (8.94 KB, text/plain)
2011-04-06 18:51 EEST, Thomas Perl
Details
List of installed packages (dpkg -l | egrep '(shiboken|pyside|qt)') (5.40 KB, text/plain)
2011-04-06 18:52 EEST, Thomas Perl
Details
Test case for bug 814 (1.02 KB, text/plain)
2011-04-08 11:17 EEST, Thomas Perl
Details
Test case for bug 814 (QML file) (110 bytes, text/plain)
2011-04-08 11:17 EEST, Thomas Perl
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Thomas Perl 2011-04-06 18:50:48 EEST
I'm using PySide 1.0.1 with Qt 4.7.2-0ubuntu6 on Ubuntu Natty.

If I try to start gPodder's QML UI, it crashes. Here's how you can get the QML
UI code:

git clone git://repo.or.cz/gpodder.git
cd gpodder
git checkout tres

Make sure to have Qt Mobility >= 1.1 installed (on Ubuntu, this can be done
using the Forum Nokia PPA), as the QML part of the application needs it. The
bug can be reproduced using:

bin/gpodder --qml

This will try to start the application, but it will crash. I'll attach a gdb
backtrace and a list of packages I've installed.
Comment 1 Thomas Perl 2011-04-06 18:51:58 EEST
Created attachment 303 [details]
gdb bactrace, obtained using "gdb --args python bin/gpodder --qml"

Here's the gdb backtrace. I've installed the Qt debug symbols, but not the
PySide/Python debug symbols. I can provide the backtrace with additional debug
symbols installed if you tell me which package I need to install.
Comment 2 Thomas Perl 2011-04-06 18:52:35 EEST
Created attachment 304 [details]
List of installed packages (dpkg -l | egrep '(shiboken|pyside|qt)')

This is the list of packages I've currently installed, obtained using:

dpkg -l | egrep '(shiboken|pyside|qt)'
Comment 3 Thomas Perl 2011-04-08 10:43:01 EEST
I just upgraded PySide from version 1.0.0 to 1.0.1 on my N900 (Maemo 5), and
now I'm experiencing this segfault on Maemo 5 as well, so this is definitely a
regression from 1.0.0 to 1.0.1, i.e. this bug doesn't exist in 1.0.0, but
exists in 1.0.1.
Comment 4 Thomas Perl 2011-04-08 11:17:00 EEST
Created attachment 306 [details]
Test case for bug 814

I've now managed to narrow down the bug and can provide a test case. You need
to either copy the QML code from the source into a new file "bug814.qml" or
copy the file bug814.qml (which I'm going to attach to this bug) in the same
directory as the test case.

Basically what I do:

 1. Subclass QAbstractListModel
 2. Instantiate the subclass
 3. Load a QML file that uses the model
 4. Set the instance as property on the rootObject

I can git-bisect the cause of this regression if you tell me in which
repository I should start looking (is searching only in "pyside" enough or
could it also be in shiboken/apiextractor/generatorrunner?).
Comment 5 Thomas Perl 2011-04-08 11:17:24 EEST
Created attachment 307 [details]
Test case for bug 814 (QML file)

Here's the QML file that you need for the test case.
Comment 6 Matti Airas 2011-04-08 11:43:23 EEST
Thomas noted on IRC that this is a regression from 1.0.0 - proposing P1
priority.
Comment 7 Thomas Perl 2011-04-08 14:38:35 EEST
I've now investigated more, and tried building different combinations and found
that the bug is somewhere in Shiboken 1.0.0 -> 1.0.1. Further investigation
using "git bisect" reveals the following commit in Shiboken to have introduced
the bug:

[b34bed93928588fef01d39a14626dce8eaf028f9] Fix bug 706 - "dataChanged signal
raise an incorrect TypeError"

HTH.
Comment 8 renato filho 2011-04-08 17:59:56 EEST
Thanks for the unittest. I agree with Mairas about the priority change and
since Hugo is not here today I will change the priority and statr to work on
this bug.
Comment 9 renato filho 2011-04-11 20:11:46 EEST
fixed on shiboken commit:

commit db6c0eec22b9a87b76ddc2888f52a71439183d1e
Author: Renato Filho <renato.filho@openbossa.org>
Date:   Mon Apr 11 11:16:30 2011 -0300
Comment 10 Thomas Perl 2011-04-11 22:24:44 EEST
I've built Git head of shiboken using the PySide buildscripts and it fixes the
issue - thanks a lot! Marking as VERIFIED.
Comment 11 Hugo Parente Lima 2011-04-13 17:41:35 EEST
As noticed by Lauro Moura it fails in an assert when running with a debug
version of Qt, hence reopening.
Comment 12 Hugo Parente Lima 2011-04-15 22:27:07 EEST
I was able to reproduce this bug in C++, so let's wait for a reply[1] from Qt
developers about that.

[1] http://bugreports.qt.nokia.com/browse/QTBUG-18801
Comment 13 renato filho 2011-04-18 16:49:06 EEST
*** Bug 796 has been marked as a duplicate of this bug. ***
Comment 14 Matti Airas 2011-04-19 13:25:54 EEST
(In reply to comment #12)
> I was able to reproduce this bug in C++, so let's wait for a reply[1] from Qt
> developers about that.
> 
> [1] http://bugreports.qt.nokia.com/browse/QTBUG-18801

There's now a reply in the upstream bug:

"modelData" role is used internally by QML. The fix will most likely be to
document that user's application should not use this role name.
Comment 15 Hugo Parente Lima 2011-04-19 17:26:09 EEST
I prefer to wait for a proper fix on Qt side, document the Qt bug isn't fix the
bug :-)
Comment 16 Matti Airas 2011-04-19 17:31:55 EEST
(In reply to comment #15)
> I prefer to wait for a proper fix on Qt side, document the Qt bug isn't fix the
> bug :-)

My comment was a quote from the upstream bug - documentation change is all
you're going to get, or else you should be prepared for a looong wait. :-p
Comment 17 Hugo Parente Lima 2011-04-19 17:37:37 EEST
(In reply to comment #16)
> (In reply to comment #15)
> > I prefer to wait for a proper fix on Qt side, document the Qt bug isn't fix the
> > bug :-)
> 
> My comment was a quote from the upstream bug - documentation change is all
> you're going to get, or else you should be prepared for a looong wait. :-p

Anyway the Qt "fix" will be automatic propagated to PySide since the PySide
docs are generated based on Qt docs.
Comment 18 Thomas Perl 2011-04-19 19:41:24 EEST
(In reply to comment #17)
> (In reply to comment #16)
> > (In reply to comment #15)
> > > I prefer to wait for a proper fix on Qt side, document the Qt bug isn't fix the
> > > bug :-)
> > 
> > My comment was a quote from the upstream bug - documentation change is all
> > you're going to get, or else you should be prepared for a looong wait. :-p
> 
> Anyway the Qt "fix" will be automatic propagated to PySide since the PySide
> docs are generated based on Qt docs.

But it shouldn't crash even when Qt has been compiled in debug mode?
Comment 19 Hugo Parente Lima 2011-04-19 20:15:45 EEST
(In reply to comment #18)
> (In reply to comment #17)
> > (In reply to comment #16)
> > > (In reply to comment #15)
> > > > I prefer to wait for a proper fix on Qt side, document the Qt bug isn't fix the
> > > > bug :-)
> > > 
> > > My comment was a quote from the upstream bug - documentation change is all
> > > you're going to get, or else you should be prepared for a looong wait. :-p
> > 
> > Anyway the Qt "fix" will be automatic propagated to PySide since the PySide
> > docs are generated based on Qt docs.
> 
> But it shouldn't crash even when Qt has been compiled in debug mode?

But it crashes, due to Qt fault. :-/
Comment 20 Thomas Perl 2011-04-19 20:29:53 EEST
(In reply to comment #19)
> (In reply to comment #18)
> > (In reply to comment #17)
> > > (In reply to comment #16)
> > > > (In reply to comment #15)
> > > > > I prefer to wait for a proper fix on Qt side, document the Qt bug isn't fix the
> > > > > bug :-)
> > > > 
> > > > My comment was a quote from the upstream bug - documentation change is all
> > > > you're going to get, or else you should be prepared for a looong wait. :-p
> > > 
> > > Anyway the Qt "fix" will be automatic propagated to PySide since the PySide
> > > docs are generated based on Qt docs.
> > 
> > But it shouldn't crash even when Qt has been compiled in debug mode?
> 
> But it crashes, due to Qt fault. :-/

Then it is a bug in Qt in my opinion that should be fixed. I assume that we
could come up with an equivalent C++ example that crashes Qt as well? Or is
there something that I'm overlooking right now?
Comment 21 Hugo Parente Lima 2011-04-19 20:40:14 EEST
(In reply to comment #20)
> Then it is a bug in Qt in my opinion that should be fixed. I assume that we
> could come up with an equivalent C++ example that crashes Qt as well? Or is
> there something that I'm overlooking right now?

I already did it and reported the bug to Qt as well.

http://bugreports.qt.nokia.com/browse/QTBUG-18801
Comment 22 renato filho 2011-04-19 21:05:50 EEST
I think we can close this bug now we know this is a Qt bug we can not replicate
all bugs from Qt on PySide bugzilla :)
Comment 23 Hugo Parente Lima 2011-04-19 21:26:35 EEST
(In reply to comment #22)
> I think we can close this bug now we know this is a Qt bug we can not replicate
> all bugs from Qt on PySide bugzilla :)

+1
Comment 24 renato filho 2011-04-29 18:06:10 EEST
PySide release 1.0.2