Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.lang.python > #98151

Re: python error

Path csiph.com!fu-berlin.de!uni-berlin.de!not-for-mail
From Terry Reedy <tjreedy@udel.edu>
Newsgroups comp.lang.python
Subject Re: python error
Date Tue, 3 Nov 2015 08:34:35 -0500
Lines 63
Message-ID <mailman.18.1446557690.8789.python-list@python.org> (permalink)
References <CALAqtxY=u7UA54cBN8wv9OTvVfdKhz_S12UDJqQ+Yq0HDgRe1Q@mail.gmail.com>
Mime-Version 1.0
Content-Type text/plain; charset=utf-8; format=flowed
Content-Transfer-Encoding 7bit
X-Trace news.uni-berlin.de wkDDmr6+6NJyWnEtVSxZpwASH5wWSzkS0YCxsBcXRgTw==
Return-Path <python-python-list@m.gmane.org>
X-Original-To python-list@python.org
Delivered-To python-list@mail.python.org
X-Spam-Status OK 0.000
X-Spam-Evidence '*H*': 1.00; '*S*': 0.00; 'essentially': 0.04; 'error:': 0.05; 'installed.': 0.05; 'properly.': 0.07; 'scripts': 0.09; '__init__': 0.09; 'received:80.91': 0.09; 'received:80.91.229': 0.09; 'received:gmane.org': 0.09; 'received:list': 0.09; 'skip:" 80': 0.09; 'python': 0.10; 'jan': 0.11; 'subject:error': 0.11; 'subject:python': 0.14; 'properly': 0.15; 'interactive,': 0.16; 'received:80.91.229.3': 0.16; 'received:io': 0.16; 'received:plane.gmane.org': 0.16; 'received:psf.io': 0.16; 'reedy': 0.16; 'scripts.': 0.16; 'tk()': 0.16; 'tkinter.': 0.16; 'wrote:': 0.16; 'tkinter': 0.22; 'am,': 0.23; 'second': 0.24; 'import': 0.24; '(most': 0.24; 'header:In- Reply-To:1': 0.24; 'header:User-Agent:1': 0.26; 'installed': 0.26; 'header:X-Complaints-To:1': 0.26; 'van': 0.26; 'skip:_ 20': 0.26; 'compatible': 0.27; 'moved': 0.27; 'looks': 0.29; 'tcl': 0.29; 'usable': 0.29; 'code:': 0.29; 'window': 0.30; 'probably': 0.31; "can't": 0.32; 'skip:_ 10': 0.32; 'directory,': 0.33; 'traceback': 0.33; 'file': 0.34; 'skip:c 30': 0.35; 'label': 0.35; 'skip:" 50': 0.35; 'problem.': 0.35; 'but': 0.36; 'should': 0.36; "wasn't": 0.36; 'to:addr:python-list': 0.36; 'subject:: ': 0.37; 'two': 0.37; 'received:org': 0.37; 'several': 0.38; 'means': 0.39; 'to:addr:python.org': 0.40; 'your': 0.60; 'times': 0.63; 'received:fios.verizon.net': 0.91
X-Injected-Via-Gmane http://gmane.org/
X-Gmane-NNTP-Posting-Host pool-173-59-124-74.phlapa.fios.verizon.net
User-Agent Mozilla/5.0 (Windows NT 10.0; WOW64; rv:38.0) Gecko/20100101 Thunderbird/38.3.0
In-Reply-To <CALAqtxY=u7UA54cBN8wv9OTvVfdKhz_S12UDJqQ+Yq0HDgRe1Q@mail.gmail.com>
X-BeenThere python-list@python.org
X-Mailman-Version 2.1.20+
Precedence list
List-Id General discussion list for the Python programming language <python-list.python.org>
List-Unsubscribe <https://mail.python.org/mailman/options/python-list>, <mailto:python-list-request@python.org?subject=unsubscribe>
List-Archive <http://mail.python.org/pipermail/python-list/>
List-Post <mailto:python-list@python.org>
List-Help <mailto:python-list-request@python.org?subject=help>
List-Subscribe <https://mail.python.org/mailman/listinfo/python-list>, <mailto:python-list-request@python.org?subject=subscribe>
Xref csiph.com comp.lang.python:98151

Show key headers only | View raw


On 11/3/2015 8:07 AM, Ruud van Rooijen wrote:
> my code:
>
> from tkinter import *
>
> window = Tk()
> label = Label(window, text="miniproject A1")
> label.pack()
> window.mainloop()
>
>
> given error:
>
> C:\Users\Ruud\Python35\Scripts\python.exe

Based on the below, python.exe should be in
C:\Users\Ruud\AppData\Local\Programs\Python\Python35-32
_tkinter should then be in
C:\Users\Ruud\AppData\Local\Programs\Python\Python35-32\DLLs

If you moved it, that is your problem.

If you have two python installations, with a second one in
C:\Users\Ruud\Python35, then python.exe should be in that directory, NOT 
scripts.

> C:/Users/Ruud/PycharmProjects/School/project.py

I know essentially nothing about PyCharm, even if it is compatible with 
tkinter.

> Traceback (most recent call last):
>
>    File "C:/Users/Ruud/PycharmProjects/School/project.py", line 3, in <module>
>
>      window = Tk()
>
>    File "C:\Users\Ruud\AppData\Local\Programs\Python\Python35-32\Lib\tkinter\__init__.py",
> line 1867, in __init__
>
>      self.tk = _tkinter.create(screenName, baseName, className,
> interactive, wantobjects, useTk, sync, use)
>
> _tkinter.TclError: Can't find a usable init.tcl in the following directories:
>
>      C:/Users/Ruud/AppData/Local/Programs/Python/Python35-32/lib/tcl8.6
> C:/Users/Ruud/Python35/lib/tcl8.6 C:/Users/Ruud/lib/tcl8.6
> C:/Users/Ruud/Python35/library C:/Users/Ruud/library
> C:/Users/Ruud/tcl8.6.4/library C:/Users/tcl8.6.4/library

With a screwed up installation, or pair of installations, it looks 
'everyplace' but the right place.

> This probably means that Tcl wasn't installed properly.

> i have repaired python several times and i can't find an answer online...
> please help

python.exe in scripts is not properly installed.

-- 
Terry Jan Reedy

Back to comp.lang.python | Previous | Next | Find similar | Unroll thread


Thread

Re: python error Terry Reedy <tjreedy@udel.edu> - 2015-11-03 08:34 -0500

csiph-web