Starting Python in XP Pro

Dave Angel davea at ieee.org
Sun Oct 17 12:17:11 CEST 2010


  On 10/16/2010 11:27 PM, Grant Andrew wrote:
> I hear that...God knows if I had a more complete question, I'd type it -
> basically, when I click the IDLE GUI icon from the Start Menu, there is a
> flash of a command prompt loading, then nothing happens.
>
> I've tried a number of things at the command prompt over the last two weeks
> and five versions.  I went to ActiveState because I was thinking I had not
> configured something properly in the Python.org versions, however, the
> behavior is the same.
>
> I ran C:\>C:\python26\lib\idlelib\idle.py at the command prompt and that
> returned:
>
> <snip>

You probably need to start with fundamentals.  That means using a 
command prompt.  As you've noticed, many times a program started from 
the start menu doesn't leave its command window open long enough to read 
the messages.

I'm afraid I can't really help with Idle;  I've never tried using it, 
till today.  When I start if from ActiveState's menu, it flashes and 
exits for me as well.  Perhaps because we both have Thinkpads.  I notice 
the IBMTools directory in your traceback.  Perhaps there's an old 
version of TCL there that's interfering with the one Idle needs.  To 
start debugging it, figure out what the menu shortcut is doing, and do 
it yourself from a command window.  In my case,  
StartIdle-right-click->properties->shortcut shows me:

Target  C:\Progfiles\ActivePython26\Lib\idlelib\idle.bat
Start in:  c:\progfiles\activePython26

So you CD to the latter directory (or rather, to your equivalent one), 
and type lib\idlelib\idle.bat

When I do that, I get an error message: "IDLE's subprocess didn't make 
connection.  Either IDLE can't start a subprocess or personal firewall 
software is blocking."

But let's get your python itself working.  ActivePython's install adds 
itself to your path, so you should be able to just type
      python
   or   python26

at the C: prompt, and get a Python interpreter prompt.  Then do 
something like
 >>> print 3*4

to see if it's working.

Next, write a small xxx.py  program, in your code directory, and NOT in 
the Python install directory.  From that code directory, type
      python  xxx.py

or whatever you called it.  Let us know if it works.

Only then should you worry about associations.  You can check them with 
assoc and ftype, but people tell me that's not reliable if there is more 
than one user on the machine, or specifically if you have created 
user-specific associations, which take precedence over the ones in assoc 
and ftype.

DaveA





More information about the Python-list mailing list