Comment 3 for bug 549126

Revision history for this message
dstaubsauger (dickerstaubsauger) wrote :

The same bug (or a very similar one) is still present in mousetrap on an up-to-date Ubuntu Precise.

When starting mousetrap from the shell the following error message appears over and over:

---

ImportError: could not import gobject (error was: ImportError('When using gi.repository you must not import static modules like "gobject". Please change all occurrences of "import gobject" to "from gi.repository import GObject".',))
Traceback (most recent call last):
  File "<string>", line 1, in <module>
  File "/usr/lib/python2.7/dist-packages/mousetrap/app/main.py", line 50, in <module>
    from lib import httpd, dbusd, settings
  File "/usr/lib/python2.7/dist-packages/mousetrap/app/lib/httpd.py", line 31, in <module>
    import mouse
  File "/usr/lib/python2.7/dist-packages/mousetrap/app/lib/mouse.py", line 30, in <module>
    import pyatspi
  File "/usr/lib/python2.7/dist-packages/pyatspi/__init__.py", line 17, in <module>
    from gi.repository import Atspi
  File "/usr/lib/python2.7/dist-packages/gi/__init__.py", line 23, in <module>
    from ._gi import _API, Repository
ImportError: could not import gobject (error was: ImportError('When using gi.repository you must not import static modules like "gobject". Please change all occurrences of "import gobject" to "from gi.repository import GObject".',))

---

The mousetrap process spawns instances of python, which cause a 100% load on one CPU.