[Python-Dev] Re: Introduction

Terence Way terry@wayforward.net
Sun, 1 Jun 2003 22:19:53 -0400


On Sunday, June 1, 2003, at 09:01  PM, Guido van Rossum wrote:

>> In summary, I prefer that DBC not be PEPed.  Instead, let things
>> grow on SF, the cookbook, the vaults, and private offerings.
>
> Good suggestions!  This can be done many ways.  Let's find ot which
> works best.
>
> --Guido van Rossum (home page: http://www.python.org/~guido/)
>

Sigh...

PEP withdrawn.

I would just like to point out, however, that the challenge with DBC
is *not* how to install contracts, whether that's done with meta-
classes, attributes, whatever.  The challenges are 1) dual use as code
and documentation, and 2) correct behavior under inheritance.

The problem with multiple implementations is that they may not work
together under inheritance, ie all super-class invariants might
not be checked, all overridden post-conditions not checked, if the
superclass and the derived class use different implementations.

What I'll do now is:
1. clean up the loose ends on my implementation; and
2. continue to write contracts for the Python standard library.  I've
    already found 1 bug :-) a full report due soon(ish).

Cheers.