GTk+Python bug in Hardy
March 21, 2008
Hey all, I have an interesting bug report to show off. I gave up on trying to run JDarkRoom for a while and tried to run PyRoom instead. It runs perfect in my Kubuntu Gutsy machine. The only problem is that I run Kubuntu Hardy on my laptop which is my everyday machine, since I’m never home for Gutsy action. This bug is in HARDY, as installing the ubuntu-desktop will still cause the same behavior. Updating from Gutsy to Hardy will not change the way Pyroom behaves and thus the bug can not be replicated this way, in Pyroom 0.1 and 0.2
hagas@morphea:~/0.2$ ./pyroom.py
Traceback (most recent call last):
File “./pyroom.py”, line 28, in
import gobject
File “/var/lib/python-support/python2.5/gtk-2.0/gobject/__init__.py”, line 30, in
from gobject.constants import *
File “/var/lib/python-support/python2.5/gtk-2.0/gobject/constants.py”, line 22, in
from _gobject import type_from_name
ImportError: /var/lib/python-support/python2.5/gtk-2.0/gobject/_gobject.so: undefined symbol: PySignal_SetWakeupFd
chagas@morphea:~/0.2$
Let’s try some magic!
chagas@morphea:~/0.2$ python
Python 2.5.2a0 (r251:54863, Jan 3 2008, 17:52:29)
[GCC 4.2.3 20071223 (prerelease) (Ubuntu 4.2.2-4ubuntu3)] on linux2
Type “help”, “copyright”, “credits” or “license” for more information.
>>> import gobject
Traceback (most recent call last):
File “”, line 1, in
File “/var/lib/python-support/python2.5/gtk-2.0/gobject/__init__.py”, line 30, in
from gobject.constants import *
File “/var/lib/python-support/python2.5/gtk-2.0/gobject/constants.py”, line 22, in
from _gobject import type_from_name
ImportError: /var/lib/python-support/python2.5/gtk-2.0/gobject/_gobject.so: undefined symbol: PySignal_SetWakeupFd
>>>
Let’s hit these files.
__init.py___ line 30 asks for an import from constants.py
from gobject.constants import *
Of course, there is more
from _gobject import type_from_name
There seems to be an error in the way the _gobject.so file is being imported and breaking my attempts to run pyroom. Amazing. ps, if there are any gtk/python people out there in the world who can fix this, I would be deeply appreciative.
-Eddie m.
[...] Holz wrote an interesting post today onHere’s a quick excerptHey all, I have an interesting bug report to show off. I gave up on trying to run JDarkRoom for a while and tried to run PyRoom instead. It runs perfect in my Kubuntu Gutsy machine. The only problem is that I run Kubuntu Hardy on my … [...]
Did you file a bug report? Things get lost easily in blogs.
I works for me on a stock hardy install:
poliahu:~ $ python
Python 2.5.2 (r252:60911, Mar 12 2008, 13:36:25)
[GCC 4.2.3 (Ubuntu 4.2.3-2ubuntu4)] on linux2
Type “help”, “copyright”, “credits” or “license” for more information.
>>> import gobject
>>>
poliahu:~ $ uname -a
Linux poliahu 2.6.24-12-generic #1 SMP Wed Mar 12 23:01:54 UTC 2008 i686 GNU/Linux
poliahu:~ $ cat /etc/issue
Ubuntu hardy (development branch) \n \l
Sounds like the _gobject.so is not linked against the python. Sounds strange, but could happen.
You can try to workardound it like this:
import sys, dl
original_flags = sys.getdlopenflags()
sys.setdlopenflags(original_flags | dl.RTLD_GLOBAL)
import gobject
sys.setdlopenflags(original_flags)
Regards,
Armin
Maybe this is related to:
http://launchpad.net/ubuntu/hardy/+source/pygobject/2.14.1-2ubuntu1