What would cause the "gi" module to be missing from python?

Posted by Catalin Dumitru on Ask Ubuntu See other posts from Ask Ubuntu or by Catalin Dumitru
Published on 2011-11-18T11:18:50Z Indexed on 2011/11/18 18:04 UTC
Read the original article Hit count: 429

Filed under:
|

After some not so clever editing of the default Python version in Ubuntu, from 2.7 to 3.2, I ended up breaking my entire system. After my computer imploded and everything stopped working, I tried to revert back my changes (by linking /usr/bin/python2.7 to /usr/bin/python and changing the default version in /usr/share/python/debian_defaults back to 2.7) but some things are still broken.

For example when I type "import gi" in the python interpreter I get the fallowing message :

>>> import gi
 Traceback (most recent call last):
 File "<stdin>", line 1, in <module>
 ImportError: No module named gi
>>> 

error which appears with some programs too (eg: gnome tweak tool). I have tried re-installing python both from the software center and from sources, but the same error persists.

Python -- version now returns :

 Python 2.7.2

and also some software packages which depend on python 2.7 are now working (for example the software center), but some things are still broken. Is there anything I can do to completely re-install python 2.7 as the default version?

© Ask Ubuntu or respective owner

Related posts about python

Related posts about libraries