Writing portably for 1.5.1 using 1.5.2

Tim Peters tim_one at email.msn.com
Sat Sep 25 13:47:46 EDT 1999


[François Pinard]
> I'm using 1.5.2 on my development machines, but have to execute
> the scripts on machines still having 1.5.1, from time to time.
> ... [example of 1.5.2's "apply" generalization] ...
> Is there, by any chance, some guide about writing Python portably
> between versions?

Nope.  Version numbers in Python increase very slowly -- 1.5.1 is well over
a year out of date, and is no longer supported.  So if you want to worry
about 1.5.1, you're on your own.

Changes are almost always backward compatible, though, so if you *need*
something that runs on both, do your development under 1.5.1.  If you insist
on making life as difficult as possible <wink>, develop under 1.5.2 but read
every line of Misc/News (in the source distribution; it summarizes the
changes from 1.5.1 to 1.5.2).

> P.S. - I got a few unexpected bugs on a given system using 1.5.2, which
> problems did not show on other 1.5.2 systems. ...

Stuff like that (straight Python having little or nothing to do with the
platform libc) is usually traced to a compiler optimization bug.  Flaky
compilers often cause one of the regression tests to fail, so first see what
happens when you do

    python Lib/test/regrtest.py

on the "bad" system.

software-not-written-in-python-doesn't-work<wink>-ly y'rs  - tim






More information about the Python-list mailing list