Take the 2-minute tour ×
Unix & Linux Stack Exchange is a question and answer site for users of Linux, FreeBSD and other Un*x-like operating systems.. It's 100% free, no registration required.
caffeine
Traceback (most recent call last):
  File "/usr/bin/caffeine", line 40, in <module>
    import caffeine
  File "/usr/lib64/python2.6/site-packages/caffeine/__init__.py", line 23, in <module>
    from gi.repository import Gtk, Gio
ImportError: No module named gi.repository

This is what I get after installing caffeine.

rpm -qa | egrep -i 'caffeine|gobject'
caffeine-2.4.419-1.el6.nux.noarch
pygobject2-2.20.0-5.el6.x86_64

How can I install it? what am I missing?

https://launchpad.net/caffeine

share|improve this question
add comment

1 Answer

Your pygobject is too old. gi.repository used to be provided by PyGI. It was merged into pygobject, but not until 2.21.4, so you either need to update pygobject or install PyGI (probably the former)

share|improve this answer
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.