Problem with Tk on Windows
Simon Foster
simon at uggs.demon.co.uk
Tue Oct 28 10:43:50 EST 2003
On Tue, 28 Oct 2003 05:21:31 +0200, Christos "TZOTZIOY" Georgiou
<tzot at sil-tec.gr> wrote:
>On Mon, 27 Oct 2003 00:46:26 GMT, rumours say that
>simon at uggs.demon.co.uk (Simon Foster) might have written:
>
>>Hi all,
>>
>>Has anyone seen the follwoing message on the Windows platform
>>when tring to use Tk?
>>
>>---
>>
>>>>> import Tkinter
>>>>> root = Tkinter.Tk()
>>Traceback (most recent call last):
>> File "<stdin>", line 1, in ?
>> File "c:\python23\lib\lib-tk\Tkinter.py", line 1564, in __init__
>> self.tk = _tkinter.create(screenName, baseName, className)
>>_tkinter.TclError: Can't find a usable init.tcl in the following
>>directories:
>> c:/python23/lib/tcl8.4 c:/lib/tcl8.4 c:/library
>
>Rhetorical: why is it searching in c:/python23/lib/tcl8.4 and not in
>c:/python23/tcl/tcl8.4, where it should be?
>
>Simon, please send the environment variables (import os; print
>os.environ) you have, and search for all init.tcl files in your hard
>drives for possible other installations. Also: which version of Python
>did you install? Or did you build it your self?
>
>Try to improvise in giving us more info, cause I can't think anything
>else now :)
I have version 2.3.2 installed. It's the windows binary direct from
the Python website. My environment looks like the following:
{'ALLUSERSPROFILE': 'C:\\Documents and Settings\\All Users.WINNT',
'APPDATA': 'C:\\Documents and Settings\\Simon
Foster.BERYLLIUM\\Application Data',
'COMPUTERNAME': 'BERYLLIUM',
'ComSpec': 'C:\\WINNT\\system32\\cmd.exe',
'CommonProgramFiles': 'C:\\Program Files\\Common Files',
'HOMEDRIVE': 'C:',
'HOMEPATH': '\\Documents and Settings\\Simon Foster.BERYLLIUM',
'LOGONSERVER': '\\\\BERYLLIUM',
'MSDevDir': 'C:\\Program Files\\Microsoft Visual
Studio\\Common\\MSDev98',
'NMAPDIR': 'C:\\Program Files\\NMapWin\\',
'NUMBER_OF_PROCESSORS': '1',
'OS': 'Windows_NT',
'Os2LibPath': 'C:\\WINNT\\system32\\os2\\dll;',
'PATHEXT': '.COM;.EXE;.BAT;.CMD;.VBS;.VBE;.JS;.JSE;.WSF;.WSH',
'PROCESSOR_ARCHITECTURE': 'x86',
'PROCESSOR_IDENTIFIER': 'x86 Family 6 Model 6 Stepping 2,
AuthenticAMD',
'PROCESSOR_LEVEL': '6',
'PROCESSOR_REVISION': '0602',
'PROMPT': '$P$G',
'PYTHONPATH': 'C:\\Documents and Settings\\Simon
Foster.BERYLLIUM\\jython-2.1\\Lib',
'Path':
'C:\\Perl\\bin\\;C:\\WINNT\\system32;C:\\WINNT;C:\\WINNT\\System32\\Wbem;C:\\Program
Files\\NMapWin\\\\bin;c:\\python23;C:\\Program
Files\\j2sdk_nb\\j2sdk1.4.2\\bin;C:\\Program Files\\Microsoft Visual
Studio\\Common\\Tools\\WinNT;C:\\Program Files\\Microsoft Visual
Studio\\Common\\MSDev98\\Bin;C:\\Program Files\\Microsoft Visual
Studio\\Common\\Tools;C:\\Program Files\\Microsoft Visual
Studio\\VC98\\bin',
'ProgramFiles': 'C:\\Program Files',
'SystemDrive': 'C:',
'SystemRoot': 'C:\\WINNT',
'TEMP': 'C:\\DOCUME~1\\SIMONF~1.BER\\LOCALS~1\\Temp',
'TMP': 'C:\\DOCUME~1\\SIMONF~1.BER\\LOCALS~1\\Temp',
'USERDOMAIN': 'BERYLLIUM',
'USERNAME': 'Simon Foster',
'USERPROFILE': 'C:\\Documents and Settings\\Simon Foster.BERYLLIUM',
'include': 'C:\\Program Files\\Microsoft Visual
Studio\\VC98\\atl\\include;C:\\Program Files\\Microsoft Visual
Studio\\VC98\\mfc\\include;C:\\Program Files\\Microsoft Visual
Studio\\VC98\\include',
'lib': 'C:\\Program Files\\Microsoft Visual
Studio\\VC98\\mfc\\lib;C:\\Program Files\\Microsoft Visual
Studio\\VC98\\lib',
'windir': 'C:\\WINNT'}
I have another init.tcl in C:\cygwin\usr\share\tcl8.4. Would that
have something to do with it? I've tried
--
Simon Foster
Somewhere in the West of England
More information about the Python-list
mailing list