execfile() - change python version?
Trung Hoang
thoa0025 at mail.usyd.edu.au
Fri Mar 29 22:46:45 EST 2002
On the other thought, using os.system(), i guess that will incur a high
performance penalty invoking an additional python interpreter wouldnt it?
like, its bad enough that python is spawned off the websever with a new
thread yeah?
is it recommended using os.system() ? just to run my scripts with python
2.2?
cheers
trungie
"Peter Hansen" <peter at engcorp.com> wrote in message
news:3CA53165.E3A765A4 at engcorp.com...
> Trung Hoang wrote:
> >
> > Hi,
> >
> > i was wondering if there is a way to change which version of python
> > processing the file when execfile().
>
> No. execfile() is basically "execute this file using the currently
> running version of Python".
>
> > i wish to use python2.2 on the main file, and python2.1 on the file
passed
> > into the argument of execfile().
>
> Don't use execfile(). Use os.system() and run the version you want
instead.
>
> > reason being: there is some sort of mis configuration error on the
server i
> > am using python on.
>
> Sounds like there must be an easier way to solve the problem. Can
> you give more detail on this "misconfiguration error"?
More information about the Python-list
mailing list