Segfault starting with 2.16.1-0ubuntu2 using Python 2.5
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
LottaNZB |
Invalid
|
Undecided
|
Unassigned | ||
pygobject (Ubuntu) |
Invalid
|
Medium
|
Unassigned |
Bug Description
A few days ago, the development version of the PyGTK application LottaNZB 0.5 (https:/
2.16.1-0ubuntu1: Works fine both using Python 2.5 and Python 2.6.
2.16.1-0ubuntu2 when launching the application using Python 2.5: Segmentation fault.
2.16.1-0ubuntu2 when launching the application using Python 2.6: Works fine.
I wasn't able to produce a simple demonstration of the Python 2.5 problem yet, but in our code the situation is as follows:
class GObjectSingleto
"""GObject singleton metaclass"""
def __init__(mcs, name, bases, _dict):
# THIS IS WHERE THE APPLICATION SEGFAULTS.
def __call__(mcs, *args, **kwargs):
"""Creates an instance of mcs if it doesn't exist yet"""
if mcs.__instance is None:
return mcs.__instance
class App(GObject, kiwi.environ.
__metaclass__ = GObjectSingleto
lock = property(
[...]
It's possible to prevent the application from segfaulting in the singleton metaclass by *either* removing the Application parent class from the App class or by removing all GObject properties from the App class.
I'm using an up-to-date Jaunty amd64 machine. I only exchanged the python-gobject package for the tests.
I'll try to provide further information about the problem and I wonder if someone else can reproduce this. You can try to reproduce the problem by branching the project and running ./run-lottanzb.sh (which will run the application using Python 2.5 by default).
Changelog of python- gobject_ 2.16.1- 0ubuntu2: https:/ /edge.launchpad .net/ubuntu/ jaunty/ +source/ pygobject/ 2.16.1- 0ubuntu2
* Remove explicit dependencies on python2.5.
* Rename -dbg extensions for python2.6 as well. LP: #333557.