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 217 - Debug build fails to run the tests (doesn't work) [_Py_AddToAllObjects: Assertion (...) failed]
: Debug build fails to run the tests (doesn't work) [_Py_AddToAllObjects: Asser...
Status: CLOSED FIXED
Product: PySide
Classification: Unclassified
Component: PySide
: 0.3.2
: All All
: P5 major
Assigned To: Didier Raboud
:
:
:
  Show dependency treegraph
 
Reported: 2010-05-10 13:44 EEST by Didier Raboud
Modified: 2010-08-04 15:09 EEST (History)
7 users (show)

See Also:


Attachments
Build log (508.34 KB, text/plain)
2010-06-22 11:22 EEST, Didier Raboud
Details
Verbose build log (557.05 KB, text/plain)
2010-06-22 11:29 EEST, Didier Raboud
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Didier Raboud 2010-05-10 13:44:28 EEST
Hi, 

I can't compile a working debug build of PySide (that runs the tests)

I use the following options:

    CMAKE_BUILD_TYPE:STRING="Debug"
    CMAKE_SKIP_RPATH=true
    CMAKE_DEBUG_POSTFIX=_d

The result is self-explanatory: 

didier@Icterus:~/Debian/pyside/build-2.6-dbg$ ctest --force-new-ctest-processes
-R qtcore_qdatastream -V
UpdateCTestConfiguration  from
:/home/didier/Debian/pyside/build-2.6-dbg/DartConfiguration.tcl
UpdateCTestConfiguration  from
:/home/didier/Debian/pyside/build-2.6-dbg/DartConfiguration.tcl
Test project /home/didier/Debian/pyside/build-2.6-dbg
Constructing a list of tests
Done constructing a list of tests
Checking test dependency graph...
test 1
    Start 1: qtcore_qdatastream

1: Test command: /bin/sh /home/didier/Debian/pyside/tests/run_test.sh
:/home/didier/Debian/pyside/build-2.6-dbg/libpyside
/home/didier/Debian/pyside/build-2.6-dbg:/home/didier/Debian/pyside/tests/util
/usr/bin/python2.6-dbg
/home/didier/Debian/pyside/tests/qtcore//qdatastream_test.py
1: Test timeout computed to be: 5
1: python2.6-dbg: ../Objects/object.c:65: _Py_AddToAllObjects: Assertion
`(op->_ob_prev == ((void *)0)) == (op->_ob_next == ((void *)0))' failed.
1: Aborted
1/1 Test #1: qtcore_qdatastream ...............***Failed    0.29 sec

0% tests passed, 1 tests failed out of 1

Total Test time (real) =   0.39 sec

The following tests FAILED:
          1 - qtcore_qdatastream (Failed)
Errors while running CTest
Comment 1 Hugo Parente Lima 2010-06-17 20:18:36 EEST
We fixed the cmakelists to work with CMAKE_SKIP_RPATH=true, could you recheck
the bug? Because it just works for me, maybe when you did the test, PySide used
old libs installed on your system, maybe... I don't know.
Comment 2 Didier Raboud 2010-06-18 03:44:24 EEST
Hi Hugo, 

when did you fix that ? Is that fixed in 0.3.2 ?

Cheers, 

OdyX
Comment 3 Didier Raboud 2010-06-18 03:46:36 EEST
By the way, the complete configure command is the following:

    -DCMAKE_BUILD_TYPE:STRING="Debug" \
    -DCMAKE_SKIP_RPATH=true \
    -DCMAKE_MODULE_PATH="$(shell pwd)/debian/cmake" \
    -DCMAKE_PYTHON_VERSION="$*-dbg;$*" \
    -DCMAKE_PYTHONLIB_VERSION="$*_d;$*" \
    -DCMAKE_DEBUG_POSTFIX=_d \
    -DLIBPYSIDE_POSTFIX=$(shell echo -py$* | sed -e 's/\.//g' -) \
    -DSHIBOKEN_POSTFIX=$(shell echo -py$* | sed -e 's/\.//g' -)

, which implies that the python version used is python2.6-dbg and the pythonlib
against which it is build is python2.6_d

Cheers, 

OdyX
Comment 4 Hugo Parente Lima 2010-06-18 15:52:18 EEST
No, it's not fixed yet, bu Renato and Setanta confirmed the bug existence.
Comment 5 Hugo Parente Lima 2010-06-21 17:51:34 EEST
Fixed, the problem was Python modules compiled in release mode which don't mix
with an interpreter compiled in debug mode and vice versa.

The fix uses Python distutils package to detect if the Python interpreter was
compiled in debug or release mode to add the proper flags to compile the
bindings.

Fixed in commit:
http://qt.gitorious.org/pyside/pyside/commit/86d0f6715ed282f7fecf789a85feb03d913ea7d9
Comment 6 Didier Raboud 2010-06-22 05:33:06 EEST
Great ! Thanks.

I'm compiling PySide with that patch right now, I'll report back !

Cheers, 

OdyX
Comment 7 Didier Raboud 2010-06-22 11:22:43 EEST
Created attachment 50 [details]
Build log

Hi, 

sorry, but I couldn't make it work. See attached build log.
Comment 8 Didier Raboud 2010-06-22 11:29:18 EEST
Created attachment 51 [details]
Verbose build log 

And now the _verbose_ build log.
Comment 9 Hugo Parente Lima 2010-06-23 10:23:32 EEST
You also needs to apply a similar patch to shiboken.
commit:

http://qt.gitorious.org/pyside/shiboken/commit/2f7c24248b6f8b398b6211f3bf6e09767ea913d8
Comment 10 Didier Raboud 2010-06-24 12:12:36 EEST
YAY ! I could finally compile both shiboken and pyside correctly, and it works
!!

Great, thank you !