Unable to run IDLE Under Windows

Collapse
This topic is closed.
X
X
 
  • Time
  • Show
Clear All
new posts
  • Jonathan Polley

    Unable to run IDLE Under Windows

    I have one account on a WindowsXP machine that refuses to run IDLE (or
    any other python script that uses Tk). Other people can login to that
    PC and IDLE runs just fine, so it is not an installation issue. When
    the person who has the problem logs into another PC the problem follows
    them. Any ideas as to what might me wrong?

    This is the traceback from IDLE:

    C:\Python20\Too ls\idle>..\..\p ython.exe idle.py
    Traceback (most recent call last):
    File "idle.py", line 12, in ?
    PyShell.main()
    File "C:\Python20\To ols\idle\PyShel l.py", line 732, in main
    root = Tk(className="I dle")
    File "c:\python20\li b\lib-tk\Tkinter.py", line 1482, in __init__
    self.tk = _tkinter.create (screenName, baseName, className)
    TclError: unknown color name "white "

    C:\Python20\Too ls\idle>

    Thanks in advance,

    Jonathan Polley

    jwpolley rockwellcollins com
  • Marian Aldenhövel

    #2
    Re: Unable to run IDLE Under Windows

    Hi,
    [color=blue]
    > Any ideas as to what might me wrong?[/color]
    [color=blue]
    > TclError: unknown color name "white "[/color]

    There is a space after "white" in this error-message. If this string comes
    from some per-user configuration that may well explain your problem.

    Ciao, MM
    --
    Marian Aldenhövel, Rosenhain 23, 53123 Bonn. +49 228 624013.

    "Wir brauchen keine Opposition, wir sind bereits Demokraten."

    Comment

    • Jonathan Polley

      #3
      Re: Unable to run IDLE Under Windows

      In article <36ofmlF533252U 1@individual.ne t>, Marian Aldenhövel
      <marian@mba-software.de> wrote:
      [color=blue]
      > Hi,
      >[color=green]
      > > Any ideas as to what might me wrong?[/color]
      >[color=green]
      > > TclError: unknown color name "white "[/color]
      >
      > There is a space after "white" in this error-message. If this string comes
      > from some per-user configuration that may well explain your problem.
      >
      > Ciao, MM[/color]

      Where do I have to go in order to fix it? It follows them from
      computer to computer...

      Thanks,

      Jonathan Polley

      Comment

      • Peter Otten

        #4
        Re: Unable to run IDLE Under Windows

        Jonathan Polley wrote:
        [color=blue]
        > I have one account on a WindowsXP machine that refuses to run IDLE (or
        > any other python script that uses Tk). Other people can login to that
        > PC and IDLE runs just fine, so it is not an installation issue. When
        > the person who has the problem logs into another PC the problem follows
        > them. Any ideas as to what might me wrong?[/color]

        Perhaps your configuration files contain bad data:

        """
        # IDLE reads several config files to determine user preferences. This
        # file is the default config file for general idle settings.
        #
        # When IDLE starts, it will look in
        # the following two sets of files, in order:
        #
        # default configuration
        # ---------------------
        # config-main.def the default general config file
        # config-extensions.def the default extension config file
        # config-highlight.def the default highlighting config file
        # config-keys.def the default keybinding config file
        #
        # user configuration
        # -------------------
        # ~/.idlerc/config-main.cfg the user general config file
        # ~/.idlerc/config-extensions.cfg the user extension config file
        # ~/.idlerc/config-highlight.cfg the user highlighting config file
        # ~/.idlerc/config-keys.cfg the user keybinding config file
        #
        # On Windows2000 and Windows XP the .idlerc directory is at
        # Documents and Settings\<usern ame>\.idlerc
        #
        # On Windows98 it is at c:\.idlerc
        """

        This is from a newer version of python, but your configuration may have a
        similar layout. The easiest way to test whether I guessed the cause of your
        troubles correctly should be to rename the .idlerc directory so that idle
        cannot find it anymore and then try to start it again.

        Peter

        Comment

        • Brian van den Broek

          #5
          Re: Unable to run IDLE Under Windows

          Peter Otten said unto the world upon 2005-02-07 09:14:[color=blue]
          > Jonathan Polley wrote:
          >
          >[color=green]
          >>I have one account on a WindowsXP machine that refuses to run IDLE (or
          >>any other python script that uses Tk). Other people can login to that
          >>PC and IDLE runs just fine, so it is not an installation issue. When
          >>the person who has the problem logs into another PC the problem follows
          >>them. Any ideas as to what might me wrong?[/color]
          >
          >
          > Perhaps your configuration files contain bad data:
          >
          > """
          > # IDLE reads several config files to determine user preferences. This
          > # file is the default config file for general idle settings.[/color]

          <SNIP details of config filenames and purposes>[color=blue]
          >
          > Peter[/color]

          Thanks for posting that, Peter. It helped me work out my problem that
          I posted about a few days back <http://tinyurl.com/3s7gn>.

          Could I ask where did you get the content from? I've searched my HDD
          for some of the contained phrases with the Windows tools I have at my
          disposal, but didn't manage to find the text you posted. (If I'd been
          able to find it, I'd have been able to solve my problem days ago.)

          Thanks and best,

          Brian vdB

          Comment

          • Peter Otten

            #6
            Re: Unable to run IDLE Under Windows

            Brian van den Broek wrote:
            [color=blue][color=green]
            >> # IDLE reads several config files to determine user preferences.  This
            >> # file is the default config file for general idle settings.[/color]
            >
            > <SNIP details of config filenames and purposes>[/color]
            [color=blue]
            > Thanks for posting that, Peter. It helped me work out my problem that
            > I posted about a few days back <http://tinyurl.com/3s7gn>.[/color]

            You're welcome.
            [color=blue]
            > Could I ask where did you get the content from? I've searched my HDD
            > for some of the contained phrases with the Windows tools I have at my
            > disposal, but didn't manage to find the text you posted. (If I'd been
            > able to find it, I'd have been able to solve my problem days ago.)[/color]

            I guess the showstopper has been the unusual suffix .def for "default
            configuration" :-)

            On Linux it's in

            /usr/local/lib/python2.4/idlelib/config-main.def

            Should be easy to translate for Windows.

            Peter

            Comment

            • maxwell@ldc.upenn.edu

              #7
              Re: Unable to run IDLE Under Windows

              Peter Otten wrote:[color=blue]
              > Perhaps your configuration files contain bad data:
              >
              > # IDLE reads several config files to determine user preferences.[/color]
              This[color=blue]
              > # file is the default config file for general idle settings.[/color]
              ....[color=blue]
              > # On Windows2000 and Windows XP the .idlerc directory is at
              > # Documents and Settings\<usern ame>\.idlerc[/color]

              I have a similar problem: I can't run the Python IDLE app (i.e. the
              file pythonw.exe), on either of two different machines. However, I'm
              using WinXP (and Python 2.4), and there is no .idlerc directory as
              listed above. One of hte machines had a .idlerc file under the Python
              dir, and renaming it didn't help. I just ran a search on the entire
              hard drive of the other machine, and the only .idlerc dir is in my
              CygWin home directory. Since I'm not trying to run idle from a CygWin
              bash shell etc., I don't think it's looking there. (Just to make sure,
              I renamed that dir...no luck.)

              I uninstalled and re-installed Python 2.4, no change. When I try to
              run pythonw.exe, there is no indication that anything happens. CPU
              usage jumps for a fraction of a second, then nothing.

              I tried running 'idle' under CygWin, and it gives the following error
              (lengthy traceback omitted, let me know if I should include that too):

              C:\cygwin\bin\p ython2.4.exe (2904): *** unable to remap
              C:\cygwin\bin\c ygssl-0.9.7.dll to same address as parent
              (0x740000) != 0x750000
              2 [main] python2.4 3080 fork_parent: child 2904 died waiting
              for dll loading

              Any other ideas why IDLE won't run?

              Comment

              • Steve Holden

                #8
                Re: Unable to run IDLE Under Windows

                maxwell@ldc.upe nn.edu wrote:[color=blue]
                > Peter Otten wrote:
                >[color=green]
                >>Perhaps your configuration files contain bad data:
                >>
                >># IDLE reads several config files to determine user preferences.[/color]
                >
                > This
                >[color=green]
                >># file is the default config file for general idle settings.[/color]
                >
                > ...
                >[color=green]
                >># On Windows2000 and Windows XP the .idlerc directory is at
                >># Documents and Settings\<usern ame>\.idlerc[/color]
                >
                >
                > I have a similar problem: I can't run the Python IDLE app (i.e. the
                > file pythonw.exe), on either of two different machines. However, I'm
                > using WinXP (and Python 2.4), and there is no .idlerc directory as
                > listed above. One of hte machines had a .idlerc file under the Python
                > dir, and renaming it didn't help. I just ran a search on the entire
                > hard drive of the other machine, and the only .idlerc dir is in my
                > CygWin home directory. Since I'm not trying to run idle from a CygWin
                > bash shell etc., I don't think it's looking there. (Just to make sure,
                > I renamed that dir...no luck.)
                >[/color]
                In this case it's possible (and this is just a guess) that you are both
                running with what are called "roaming profiles". In this case your
                ".idlerc" file may appear somewhere on a network drive that's
                automatically mapped rather than a subdirectory of C:\Documents and
                Settings.

                You should be able to find it under XP with the command

                echo %HOMEPATH%

                Take a look in that directory and see if there's an .idlerc.
                [color=blue]
                > I uninstalled and re-installed Python 2.4, no change. When I try to
                > run pythonw.exe, there is no indication that anything happens. CPU
                > usage jumps for a fraction of a second, then nothing.
                >[/color]
                You wouldn't expect anything - pythonw.exe is the no-console
                interpreter, so if you don;t give it a program to run it will terminate
                pretty much immediately, and if the program doesn't use windowing then
                you won't see anything happen even if you *do* run something.

                I presume you *can* run python.exe :-)

                If so then try running IDLE with python -v to get more information about
                what's going on.
                [color=blue]
                > I tried running 'idle' under CygWin, and it gives the following error
                > (lengthy traceback omitted, let me know if I should include that too):
                >
                > C:\cygwin\bin\p ython2.4.exe (2904): *** unable to remap
                > C:\cygwin\bin\c ygssl-0.9.7.dll to same address as parent
                > (0x740000) != 0x750000
                > 2 [main] python2.4 3080 fork_parent: child 2904 died waiting
                > for dll loading
                >[/color]
                This is a known issue with Cygwin. Fortunately you can fix it with the
                rebaseall command. You could try the following steps to fix Cygwin,
                which is currently unable to load a DLL at the same address in a forked
                sub-process. Note this is voodoo, so no guarantees ...


                1. Close all Cygwin windows (and stop Cygwin services, if any are running).

                2. In a new standard Cygwin command interpreter window run

                rebaseall -v

                That should be it.
                [color=blue]
                > Any other ideas why IDLE won't run?
                >[/color]
                Well, that's a few things to think about, anyway.

                regards
                Steve
                --
                Meet the Python developers and your c.l.py favorites March 23-25
                Come to PyCon DC 2005 http://www.pycon.org/
                Steve Holden http://www.holdenweb.com/

                Comment

                • maxwell@ldc.upenn.edu

                  #9
                  Re: Unable to run IDLE Under Windows

                  Thanks, guess I misunderstood--I thought "pythonw" _was_ IDLE. Now I
                  see what IDLE is, and I wasn't actually wanting to run that.

                  And as it turns out, my _real_ problem was that my path was making me
                  run the CygWin version of Python from the "DOS" command prompt--which
                  understandably dies with a "CPU" error.

                  Now I'm squared away--thanks for the tip!

                  Comment

                  Working...