Re: [gtk-osx-users] ImportError: No module named gi.




Le 31 mars 2019 à 04:50, John Ralls <jralls ceridwen fremont ca us> a écrit :

On Mar 30, 2019, at 1:31 PM, Pascal <abo pignard wanadoo fr> wrote:


Le 30 mars 2019 à 20:24, Timo via gtk-osx-users-list <gtk-osx-users-list gnome org> a écrit :

Op 30/03/19 om 18:55 schreef Pascal:
Hello John,

Sorry, my wording was incorrect.
$ jhbuild build pygobject
is built without any error.
But I've got "ImportError ... gi" when running my app.
Did you enter the jhbuild shell before running your app? Something like this:

$ jhbuild shell
$ ./my_app.py

Or try with the interpreter first:  (still within jhbuild shell)
$ python
from gi.repository import Gtk

Hello Timo, I get:

$ jhbuild shell
Prefix: /usr/local/xnadalib-2018
Entered jhbuild shell, type 'exit' to return.

[JH] $ which python
/usr/local/xnadalib-2018/bin/python

[JH] $ python
Python 2.7.14 (default, Sep 13 2018, 10:35:57) 
[GCC 4.2.1 Compatible Apple LLVM 9.1.0 (clang-902.0.39.2)] on darwin
Type "help", "copyright", "credits" or "license" for more information.
from gi.repository import Gtk
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
ImportError: No module named gi.repository

You said that pygobject built and installed correctly. Where did it install gi?

Hello John,

When I installed python (2) and pygobject, I can't see any "gi" in 
../usr/local/xnadalib-2018/lib/python2.7/site-packages.
Thus I wonder if gi does not come only with pygobject3.

Regards, Pascal.
http://blady.pagesperso-orange.fr




[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]