[Tutor] Can't Launch IDLE from Linux System

Bruce Sass bsass@freenet.edmonton.ab.ca
Mon, 5 Mar 2001 14:25:42 -0700 (MST)


On Mon, 5 Mar 2001, Britt Green wrote:

> Howdy,
>
> I just got Mandrake 7.2 up and running. When I try to start IDLE, I get the
> following error message:
>
> [cheshire@C718841-B cheshire]$ idle
> Traceback (most recent call last):
>   File "/usr/lib/python1.5/site-packages/idle/idle.py", line 2, in ?
                  ^^^^^^^^^^^
>     import PyShell
>   File "/usr/lib/python1.5/site-packages/idle/PyShell.py", line 12, in ?
                  ^^^^^^^^^^^
>     from Tkinter import *
>   File "/usr/local/lib/python2.0/lib-tk/Tkinter.py", line 35, in ?
                        ^^^^^^^^^^^ !
>     import _tkinter # If this fails your Python may not be configured for Tk
> ImportError: No module named _tkinter
> [cheshire@C718841-B cheshire]$

Python 1.5.2 comes with Mandrake, and you installed Python 2.0
yourself, right.

> How can I fix this?

My solution was to build and install tcl/tk8.3, then tell the py-2.0
executables to use python2.0 instead of python (the .../Tools/fixps.py
script will help, but you will need to tweak it yourself).

re: tcl/tk
You may want to rebuild py-2.0 to use whatever 8.x of tcl/tk you have,
I've heard of it being done (but don't know what to do, ottomh)... but
you should still tell the py-2.0 stuff to use the python2.0
interpreter if you want 1.5.2 and 2.0 to coexist.


- Bruce