Python 2.0

Martijn Faassen m.faassen at vet.uu.nl
Thu Apr 27 14:36:45 CEST 2000


Wayne Izatt <wayne.izatt at myself.com> wrote:
[will Python 2.0 cause a maintenance problem]
> So, can anyone give me any advice? Is there any cause for alarm?

First of all, the 1.x line of development is definitely good for a few
years yet at least. I doubt Python 1.6 will be superceded by Python 1.7
within a year, and Python 1.6 isn't even out yet. Python 1.7, which is
being planned, is surely going to last at least a year more. That brings us
to the summer of 2002. That's centuries in computing-history time. 2 years
ago I don't even think C++ was standardized yet, for instance. Or just take
Java back in '98. That should put things in perspective; Python's development
tends to be cautious, the current code base is good for years yet.

Now on to Python 2.0. It's been said before on this newsgroup that while
Python 2.0 is expected to break the C API for Python, it's not thought it'll
break a lot of code written in Python. Perhaps they know more than I do, but
I myself am a bit more dubious about this for two reasons:

  * it might be *good* for the language to ignore backward compatibility for
    a change. Things that are broken now can be fixed for good. Not that
    a lot of things are broken, but there are some candidates for improvement.
    lambdas for instance. We *want* to break existing code. :)

  * we only know a few things that are thought about for Python 2.0, and if
    these are implemented we'd get large backwards incompatibility problems:

      * integer division giving float results. 1/2 might suddenly give us 0.5

      * case insensitivity. foo = Foo() would break
 
    Both of these are catering to beginners. Opinions on them vary; 
    they may reek a bit like Do-What-I-Mean, but nobody thinks either change
    would be a disaster. But both proposed changes would definitely
    break tons of existing Python code.

That said, there will probably be at least some code migration tools. They can
probably not be perfectly automated in all cases; humans will be necessary.

Concluding my analysis:

  * current Python codebase is good for almost the indefinite future. A mature
    Python 2.0 replacing Python 1.x is years away.

  * Python 2.0 is bound to break quite a bit of existing code, when it 
    happens.

  * No cause for alarm yet.

Someone should put this question into a FAQ or something -- it's being asked
quite frequently these days.

Regards,

Martijn 
-- 
History of the 20th Century: WW1, WW2, WW3?
No, WWW -- Could we be going in the right direction?



More information about the Python-list mailing list