Re: [Tutor] Wrong version of Python being executed

2007-11-19 Thread Alan Gauld
"Tony Cappellini" <[EMAIL PROTECTED]> wrote > So I've changed the association from the 2.3 icon to the 2.5 icon, > and > now I can run my script from the command line as follows > > python script.py, and the correct version of Python is invoked. > > This is very disturbing because it means the pa

Re: [Tutor] Wrong version of Python being executed

2007-11-19 Thread Tony Cappellini
I've found something interesting regarding this issue. I went to Windows Explorer, Tools,Folder Options, File Types and noticed that there are two different icons associated with .PY files. The Icon for Python 2.5 is easy to recognize as compared with the icon for Python 2.3. So I've changed the

Re: [Tutor] Wrong version of Python being executed

2007-11-12 Thread Tony Cappellini
Date: Mon, 12 Nov 2007 09:14:05 - From: "Alan Gauld" <[EMAIL PROTECTED]> Subject: Re: [Tutor] Wrong version of Python being executed To: tutor@python.org Message-ID: <[EMAIL PROTECTED]> Content-Type: text/plain; format=flowed; charset="iso-8859-1"; reply-

Re: [Tutor] Wrong version of Python being executed

2007-11-12 Thread Martin Walsh
Alan Gauld wrote: > "Tony Cappellini" <[EMAIL PROTECTED]> wrote > >> I have to switch between 2.3 and 2.5, so to make it easy, I use an >> environment variable called CURRENT_PYTHON. >> (someone on this list or the wxPython list told me I should NOT use >> PYTHONPATH and modify it the way I am usi

Re: [Tutor] Wrong version of Python being executed

2007-11-12 Thread Alan Gauld
"Tony Cappellini" <[EMAIL PROTECTED]> wrote > I have to switch between 2.3 and 2.5, so to make it easy, I use an > environment variable called CURRENT_PYTHON. > (someone on this list or the wxPython list told me I should NOT use > PYTHONPATH and modify it the way I am using CURRENT_PYTHON) > > CU

Re: [Tutor] Wrong version of Python being executed

2007-11-11 Thread Tony Cappellini
Message: 2 Date: Sun, 11 Nov 2007 16:57:01 -0600 From: Martin Walsh <[EMAIL PROTECTED]> Subject: Re: [Tutor] Wrong version of Python being executed To: Tutor Python Message-ID: <[EMAIL PROTECTED]> Content-Type: text/plain; charset=ISO-8859-1 >>My initial thought based on yo

Re: [Tutor] Wrong version of Python being executed

2007-11-11 Thread Alan Gauld
"Martin Walsh" <[EMAIL PROTECTED]> wrote Try using the full path to python, just to be sure: c:\python25\python script.py -- do you get the same behavior? >> This works just fine- I would expect it to. > > Actually, I would have expected the opposite. Me too. > Though this still

Re: [Tutor] Wrong version of Python being executed

2007-11-11 Thread Martin Walsh
Tony Cappellini wrote: > Martin Walsh mwalsh at groktech.org > Sun Nov 11 06:13:10 CET 2007 > >>> That is odd. > >>> Try using the full path to python, just to be sure: c:\python25\python >>> script.py -- do you get the same behavior? > This works just fine- I would expect it to. Actually, I wou

Re: [Tutor] Wrong version of Python being executed

2007-11-11 Thread Tony Cappellini
Martin Walsh mwalsh at groktech.org Sun Nov 11 06:13:10 CET 2007 >>That is odd. >>Try using the full path to python, just to be sure: c:\python25\python >>script.py -- do you get the same behavior? This works just fine- I would expect it to. >>Also, if you haven't already, you can run python wit

Re: [Tutor] Wrong version of Python being executed

2007-11-10 Thread Martin Walsh
Tony Cappellini wrote: >>> What do you get if you print sys.path from >> the interpreter? > > I've printed out sys.path from inside the script as well, > and all references to Python25 are replaced with Python23 > > > FWIW- This isn't a problem unique to this script. > I've just printed out sys.

Re: [Tutor] Wrong version of Python being executed

2007-11-10 Thread Tony Cappellini
>>What do you get if you print sys.path from > the interpreter? I've printed out sys.path from inside the script as well, and all references to Python25 are replaced with Python23 FWIW- This isn't a problem unique to this script. I've just printed out sys.path from another script in another dire

Re: [Tutor] Wrong version of Python being executed

2007-11-10 Thread Tony Cappellini
Thanks for replying Kent. This is quite a strange mystery. > A couple of possibilities... > Is there a #! line at the start of the script that specifies Python 2.3 > (I'm not sure if those work in windows though...) No- The shebang line is for non-Windows systems (Unix variants) > How do you run

Re: [Tutor] Wrong version of Python being executed

2007-11-10 Thread Kent Johnson
Tony Cappellini wrote: > When I run this python script, the following exception is thrown, > implying that it is being executed with Python 2.3 > So I've added this print statement to the main function, which shows > the logging module is being imported from the Python 2.3 directory > > print"\nlo

[Tutor] Wrong version of Python being executed

2007-11-10 Thread Tony Cappellini
I've got Python 2.3, 2.4 and 2.5 installed on a Windows XP machine.. I currently have Python 2.5 in my path, and there are no other versions of Python in the path. I'm trying to run a program which expects Python 2.4 or later to be installed, because there is a call to logging.BasicConfig(arg1, a