PEP 238 (revised)

piet at cs.uu.nl piet at cs.uu.nl
Fri Jul 27 05:16:47 EDT 2001


>>>>> Chris Barker <chrishbarker at home.net> (CB) writes:

CB> Guido van Rossum wrote:
>> 
>> Here's a completely revised version of PEP 238. 

CB> Very nice. Let's hope this calms the waters some...

>> - Use a directive (or some other way) to specify the Python
>> version for which a specific piece of code was developed.  This
>> requires future Python interpreters to be able to emulate
>> *exactly* every previous version of Python, and moreover to do
>> so for multiple versions in the same interpreter.  This is way
>> too much work.  A much simpler solution is to keep multiple
>> interpreters installed.

CB> I think this has been dismissed a little too quickly. I suppose I can't
CB> comment on what "way too much work" is, as I really don't know how much
CB> work it will be, and I'm unlikely to be doing any of it. I do think that
CB> it is a lot of work for system administrators to keep all the old
CB> interpreters around (particularly on new systems, it could be a fair bit
CB> of work to get a working copy of Python 2.1 on RedHat 13.2 a few years
CB> from now!) It seems to me that the worst case is that we end up with a
CB> somewhat bloated interpreter that is essentially two (or three, or four)
CB> completely separate interpreters that happen to be bundled together.
CB> Given how cheap memory and disk space is these days, the bloat shouldn't
CB> be a big deal, and you could always turn off the old code with a compile
CB> option if you didn't need the backwards compatible interpreter.

I agree with Chris, including the stuff I have cut away. Having different
interpreters installed is a pain, and doesn't solve the problem of using
old modules that you got somewhere mixed with new code. If the modules were
not written by yourself and too complicated to adapt them you are stuck.

See also my proposal for a `module' statement. Developers could add a
parameter with the python version for which the module was written, e.g.

module mymodule(2.4) or
module mymodule(version=2.4)

So this would be a possibility for `eternal programming'.
-- 
Piet van Oostrum <piet at cs.uu.nl>
URL: http://www.cs.uu.nl/~piet [PGP]
Private email: P.van.Oostrum at hccnet.nl



More information about the Python-list mailing list