FAQ
Greetings,


I'm trying to teach Python to some linguistics students who are new to
programming. The last time I did this was 2 years ago, with Python 2.1 and
IDLE. (Windows environment.) At the time, everything went smoothly except
installation; as I recall Python 2.1 wrote its links into Administrator's
start menu instead of All Users' start menu, and I had to move them. But
once moved, it worked well.

Fast forward to 2004. Following Ron Zacharski's "Python for Linguists," I
choose ActiveState Python. It installs very smoothly but, but the IDE,
which is called Pythonwin, is frustrating in two respects:

- If the program has a serious syntax error, you don't get any error
messages in the interaction window. There is only a brief note in the
status line at the bottom of the screen. This is *very* frustrating to my
students.

- In the IDE, input() and raw_input() pop up an input box. On the console,
they simply wait for input. The disparity is annoying to students who are
basically learning the console paradigm. It becomes excessively hard to
write an interactive console program with the IDE.

So on my Windows XP laptop just now, I de-installed Python 2.1 and
ActiveState Python 2.3, and went and downloaded Python 2.3.3 from
www.python.org.

All looks good except - IDLE won't start at all!!! I try to launch it, get
a few seconds of the hourglass cursor, and it's gone, with nothing on the
screen and no processes running!

Rebooting didn't cure this. What gives?


--

Michael A. Covington - Artificial Intelligence Ctr - University of Georgia

"In the core C# language it is simply not possible to have an uninitialized
variable, a 'dangling' pointer, or an expression that indexes an array
beyond its bounds. Whole categories of bugs that routinely plague C and C++
programs are thus eliminated." - A. Hejlsberg, The C# Programming Language

Search Discussions

  • Michael A. Covington at Mar 24, 2004 at 1:36 am
    On the trail of figuring out why IDLE won't launch, look at this:

    Python 2.3.3 (#51, Dec 18 2003, 20:22:39) [MSC v.1200 32 bit (Intel)] on
    win32
    Type "help", "copyright", "credits" or "license" for more information.
    import Tkinter
    Tkinter._test()
    Traceback (most recent call last):
    File "<stdin>", line 1, in ?
    File "C:\PYTHON23\lib\lib-tk\Tkinter.py", line 3640, in _test
    root = Tk()
    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:\WN16\LIB\TCL7.6} {C:\WN16\LIB\TCL7.6} C:/WN16/LIB/tcl8.4
    C:/Python23/lib/tcl8.4 C:/lib/tcl8.4 C:/library
    This probably means that Tcl wasn't installed properly.
    >>>


    Here \WN16 is where *another* TCL/TK application *used* to reside. And the
    TCL stuff definitely *does* exist under C:\Python23\tcl\tcl8.4 (not
    lib\tcl8.4).

    By default does Python 2.3.3 install itself incorrectly???!!
  • Michael A. Covington at Mar 24, 2004 at 1:44 am
    Further, Python 2.3.2 has the same problem, but with 8.3 in place of 8.4
    throughout.


    "Michael A. Covington" <look at www.covingtoninnovations.com.for.address> wrote
    in message news:PoidnWghOfqve_3dRVn_iw at speedfactory.net...
    On the trail of figuring out why IDLE won't launch, look at this:

    Python 2.3.3 (#51, Dec 18 2003, 20:22:39) [MSC v.1200 32 bit (Intel)] on
    win32
    Type "help", "copyright", "credits" or "license" for more information.
    import Tkinter
    Tkinter._test()
    Traceback (most recent call last):
    File "<stdin>", line 1, in ?
    File "C:\PYTHON23\lib\lib-tk\Tkinter.py", line 3640, in _test
    root = Tk()
    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:\WN16\LIB\TCL7.6} {C:\WN16\LIB\TCL7.6} C:/WN16/LIB/tcl8.4
    C:/Python23/lib/tcl8.4 C:/lib/tcl8.4 C:/library
    This probably means that Tcl wasn't installed properly.

    Here \WN16 is where *another* TCL/TK application *used* to reside. And the
    TCL stuff definitely *does* exist under C:\Python23\tcl\tcl8.4 (not
    lib\tcl8.4).

    By default does Python 2.3.3 install itself incorrectly???!!


  • Michael A. Covington at Mar 24, 2004 at 5:23 am
    Somehow, after reinstalling, it started working OK. And on another computer
    it gave no trouble.

    "Michael A. Covington" <look at www.covingtoninnovations.com.for.address> wrote
    in message news:6ZydnUx5GLGadf3dRVn-sw at speedfactory.net...
    Further, Python 2.3.2 has the same problem, but with 8.3 in place of 8.4
    throughout.


    "Michael A. Covington" <look at www.covingtoninnovations.com.for.address> wrote
    in message news:PoidnWghOfqve_3dRVn_iw at speedfactory.net...
    On the trail of figuring out why IDLE won't launch, look at this:

    Python 2.3.3 (#51, Dec 18 2003, 20:22:39) [MSC v.1200 32 bit (Intel)] on
    win32
    Type "help", "copyright", "credits" or "license" for more information.
    import Tkinter
    Tkinter._test()
    Traceback (most recent call last):
    File "<stdin>", line 1, in ?
    File "C:\PYTHON23\lib\lib-tk\Tkinter.py", line 3640, in _test
    root = Tk()
    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:\WN16\LIB\TCL7.6} {C:\WN16\LIB\TCL7.6} C:/WN16/LIB/tcl8.4
    C:/Python23/lib/tcl8.4 C:/lib/tcl8.4 C:/library
    This probably means that Tcl wasn't installed properly.

    Here \WN16 is where *another* TCL/TK application *used* to reside. And the
    TCL stuff definitely *does* exist under C:\Python23\tcl\tcl8.4 (not
    lib\tcl8.4).

    By default does Python 2.3.3 install itself incorrectly???!!


  • Michael A. Covington at Mar 24, 2004 at 1:48 am
    My other curiosity is how it remembers that Tcl/Tk used to be in \WN16,
    which no longer exists. That information is not in the Registry.

    "Michael A. Covington" <look at www.covingtoninnovations.com.for.address> wrote
    in message news:PoidnWghOfqve_3dRVn_iw at speedfactory.net...
    On the trail of figuring out why IDLE won't launch, look at this:

    Python 2.3.3 (#51, Dec 18 2003, 20:22:39) [MSC v.1200 32 bit (Intel)] on
    win32
    Type "help", "copyright", "credits" or "license" for more information.
    import Tkinter
    Tkinter._test()
    Traceback (most recent call last):
    File "<stdin>", line 1, in ?
    File "C:\PYTHON23\lib\lib-tk\Tkinter.py", line 3640, in _test
    root = Tk()
    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:\WN16\LIB\TCL7.6} {C:\WN16\LIB\TCL7.6} C:/WN16/LIB/tcl8.4
    C:/Python23/lib/tcl8.4 C:/lib/tcl8.4 C:/library
    This probably means that Tcl wasn't installed properly.

    Here \WN16 is where *another* TCL/TK application *used* to reside. And the
    TCL stuff definitely *does* exist under C:\Python23\tcl\tcl8.4 (not
    lib\tcl8.4).

    By default does Python 2.3.3 install itself incorrectly???!!


  • Michael A. Covington at Mar 24, 2004 at 2:57 pm
    "Dennis Lee Bieber" <wlfraed at ix.netcom.com> wrote in message
    news:l2a260lj050pch3sq57vfp29rsq099tgp9 at 4ax.com...
    On Tue, 23 Mar 2004 20:48:19 -0500, "Michael A. Covington"
    <snip>
    My apologies... The name seems familiar... "Astrophotography for
    the Amateur", by chance?
    That's me! Since I lead a double life, I'll give you both signature blocks
    below...

    By the way, the deal with WN16 was - can you believe it - an AUTOEXEC.BAT
    file! I didn't know such things would even still run under Windows XP, but
    there it was.

    WN16 is WordNet 1.6, from Princeton University, basically a huge synonym
    dictionary of English. They are up to version 2.0 now and it's much better
    behaved. The open-source community is _finally_ learning something about
    how Windows works. For a while there, inept Windows configuration seemed to
    be a point of pride with some kinds of free software tools!


    ----------------------------------------------------------------------------
    ---------
    Michael A. Covington, Associate Director
    Artificial Intelligence Center, The University of Georgia
    http://www.ai.uga.edu/~mc

    --
    Michael Covington -- www.covingtoninnovations.com
    Author, Astrophotography for the Amateur
    and (new) How to Use a Computerized Telescope
  • David MacQuigg at Mar 24, 2004 at 7:53 pm

    On Wed, 24 Mar 2004 09:57:35 -0500, "Michael A. Covington" wrote:

    WN16 is WordNet 1.6, from Princeton University, basically a huge synonym
    dictionary of English. They are up to version 2.0 now and it's much better
    behaved. The open-source community is _finally_ learning something about
    how Windows works. For a while there, inept Windows configuration seemed to
    be a point of pride with some kinds of free software tools!
    I believe the problem lies with Microsoft for obfuscating the
    installation process. As good as they have done with usability for
    the typical office user, they seem to have a deliberate strategy of
    making things more complex than they need to be at the system level.
    The registry is a prime example. Another is the monolithic
    integration of the desktop with the OS. There are many such examples.
    It's all part of the Lock In Strategy of software development.

    Open-source developers are often not as expert in Windows
    installations as a typical commercial developer targeting the Windows
    platform. We cannot blame them for falling into a few Microsoft
    traps. It's not like they don't *want* their programs to run on
    Windows, or that they are "proud" of the problems they cause for
    Windows users. A few may a have a "don't care" attitude, but most
    just don't realize that when they set a variable in AUTOEXEC.BAT, it
    can mess up another program like IDLE.

    Given the reality that other programs will be making blunders in their
    installations, we should still be able to detect a bad setup for IDLE
    and at least warn the user -- "Some other program has set the default
    TCL/TK library to version 8.2. IDLE cannot be installed unless you
    remove the variable TCLxxxNNN from the current environment.

    -- Dave
  • Michael A. Covington at Mar 25, 2004 at 10:27 pm
    "David MacQuigg" <dmq at gain.com> wrote in message
    news:vho3609it1bc3nnqui3e5ii8e3kupgl0c2 at 4ax.com...
    On Wed, 24 Mar 2004 09:57:35 -0500, "Michael A. Covington"
    wrote:
    WN16 is WordNet 1.6, from Princeton University, basically a huge synonym
    dictionary of English. They are up to version 2.0 now and it's much
    better
    behaved. The open-source community is _finally_ learning something about
    how Windows works. For a while there, inept Windows configuration seemed
    to
    be a point of pride with some kinds of free software tools!
    I believe the problem lies with Microsoft for obfuscating the
    installation process. As good as they have done with usability for
    the typical office user, they seem to have a deliberate strategy of
    making things more complex than they need to be at the system level.
    The registry is a prime example. Another is the monolithic
    integration of the desktop with the OS. There are many such examples.
    It's all part of the Lock In Strategy of software development.
    I think the real problem here is simply that WordNet 1.6 was *old*. It
    smacked of Windows 3, which has much less orderly installation methods than
    we have nowadays.
  • Michael A. Covington at Mar 24, 2004 at 2:58 pm
    "Dennis Lee Bieber" <wlfraed at ix.netcom.com> wrote in message
    news:l2a260lj050pch3sq57vfp29rsq099tgp9 at 4ax.com...
    ============================================================== <
    wlfraed at ix.netcom.com | Wulfraed Dennis Lee Bieber KD6MOG <

    VY 73 DE N4TMI
    Michael
  • Tim Peters at Mar 24, 2004 at 2:18 am
    [Michael A. Covington]
    On the trail of figuring out why IDLE won't launch, look at this:

    Python 2.3.3 (#51, Dec 18 2003, 20:22:39) [MSC v.1200 32 bit (Intel)]
    on win32
    Type "help", "copyright", "credits" or "license" for more information.
    import Tkinter
    Tkinter._test()
    Traceback (most recent call last):
    File "<stdin>", line 1, in ?
    File "C:\PYTHON23\lib\lib-tk\Tkinter.py", line 3640, in _test
    root = Tk()
    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:\WN16\LIB\TCL7.6} {C:\WN16\LIB\TCL7.6} C:/WN16/LIB/tcl8.4
    C:/Python23/lib/tcl8.4 C:/lib/tcl8.4 C:/library
    This probably means that Tcl wasn't installed properly.
    Here \WN16 is where *another* TCL/TK application *used* to reside.
    And the TCL stuff definitely *does* exist under
    C:\Python23\tcl\tcl8.4 (not lib\tcl8.4).

    By default does Python 2.3.3 install itself incorrectly???!!
    No, it means Python is a good citizen but WN16 was a criminal <wink>.

    Installing Python won't interfere with any other Tcl/Tk-using app on your
    system, because Python is polite and considerate.

    WN16 probably set an environment variable, or more than one, forcing every
    Tcl/Tk on the box to use the old version WN16 installed. That's anti-social
    of it, but not Python's doing. Do "set | sort" from a DOS box, and look for
    envars with names starting with TCL or TK. I'm betting you'll find at least
    one, pointing to a directory under C:\WIN16. If you do, get rid of it, and
    then Tkinter should work fine.
  • David MacQuigg at Mar 24, 2004 at 2:33 am

    On Tue, 23 Mar 2004 20:12:53 -0500, "Michael A. Covington" wrote:

    All looks good except - IDLE won't start at all!!! I try to launch it, get
    a few seconds of the hourglass cursor, and it's gone, with nothing on the
    screen and no processes running!

    Rebooting didn't cure this. What gives?
    This is a common problem with lots of causes. Do a Google search on
    'start IDLE group:comp.lang.python'

    Here is one good thread:
    IDLE won't start 13-Oct-2003
    http://www.google.com/groups?hl=en&lr=&ie=UTF-8&oe=UTF-8&threadm�4l30tn66bhni11hdatu8ot7uvpme8h13%404ax.com&rnum&prev=/groups%3Fq%3Dstart%2BIDLE%2Bgroup:comp.lang.python%26hl%3Den%26lr%3D%26ie%3DUTF-8%26oe%3DUTF-8%26scoring%3Dd%26selm%3D9b4l30tn66bhni11hdatu8ot7uvpme8h13%25404ax.com%26rnum%3D10

    In spite of these problems, I'm very happy with IDLE. Once you get it
    working, it is ideal for students. I also use it in my development
    work, along with Qt Designer for the GUI part.

    -- Dave
  • Michael A. Covington at Mar 24, 2004 at 5:27 am

    In spite of these problems, I'm very happy with IDLE. Once you get it
    working, it is ideal for students.
    Having spent the evening working with it, I agree.

    My notes:
    http://www.ai.uga.edu/mc/idle

    Thanks to all!
  • Michael A. Covington at Mar 24, 2004 at 5:24 am
    "Tim Peters" <tim.one at comcast.net> wrote in message
    news:mailman.312.1080094713.742.python-list at python.org...
    [Michael A. Covington]
    On the trail of figuring out why IDLE won't launch, look at this:

    Python 2.3.3 (#51, Dec 18 2003, 20:22:39) [MSC v.1200 32 bit (Intel)]
    on win32
    Type "help", "copyright", "credits" or "license" for more information.
    import Tkinter
    Tkinter._test()
    Traceback (most recent call last):
    File "<stdin>", line 1, in ?
    File "C:\PYTHON23\lib\lib-tk\Tkinter.py", line 3640, in _test
    root = Tk()
    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:\WN16\LIB\TCL7.6} {C:\WN16\LIB\TCL7.6} C:/WN16/LIB/tcl8.4
    C:/Python23/lib/tcl8.4 C:/lib/tcl8.4 C:/library
    This probably means that Tcl wasn't installed properly.
    Here \WN16 is where *another* TCL/TK application *used* to reside.
    And the TCL stuff definitely *does* exist under
    C:\Python23\tcl\tcl8.4 (not lib\tcl8.4).

    By default does Python 2.3.3 install itself incorrectly???!!
    No, it means Python is a good citizen but WN16 was a criminal <wink>.

    Installing Python won't interfere with any other Tcl/Tk-using app on your
    system, because Python is polite and considerate.

    WN16 probably set an environment variable, or more than one, forcing every
    Tcl/Tk on the box to use the old version WN16 installed. That's
    anti-social
    of it, but not Python's doing. Do "set | sort" from a DOS box, and look for
    envars with names starting with TCL or TK. I'm betting you'll find at least
    one, pointing to a directory under C:\WIN16. If you do, get rid of it, and
    then Tkinter should work fine.
    Thanks. Sure enough, it did. I'll zap 'em.

Related Discussions

Discussion Navigation
viewthread | post
Discussion Overview
grouppython-list @
categoriespython
postedMar 24, '04 at 1:12a
activeMar 25, '04 at 10:27p
posts13
users3
websitepython.org

People

Translate

site design / logo © 2022 Grokbase