You are not logged in.
Hello!
I just started a new project in python using pygtk. I never used pygtk before, so I started with copying some code from the pygtk tutorial. It worked as expected and I was well on my way to implementing the things I wanted.
Couple of days later, I worked on it some more, but now I get "ModuleNotFoundError: No module named 'pygtk'".
According to Pacman it's installed. I triend uninstalling and reinstalling but Pacman didn't allow it because I have a lot of dependecies.
To test i'm trying to run this file: http://www.pygtk.org/pygtk2tutorial/exa … loworld.py
Which I had to convert to python 3 by changing the "print 'xxxx'" to "print('xxx')".
Maybe my Pythonpath got screwed up?
Python output of sys.path is :
['', '/usr/lib/python36.zip', '/usr/lib/python3.6', '/usr/lib/python3.6/lib-dynload', '/usr/lib/python3.6/site-packages']
The only reference to pygtk in those folders, is a directory called "pygtkcompat" in /usr/lib/python3.6/site-packages/
Any ideas how to fix this?
Last edited by legacy.nl (2017-03-26 12:48:34)
Offline
Oh oops, such a rookie mistake.
Using "#!/usr/bin/env python2" it works!.
Thanks.
Offline