Contracts for Python

Chris Rebert clp at
Tue Oct 28 19:51:47 CET 2008

On Tue, Oct 28, 2008 at 10:47 AM, Paulo J. Matos <pocmatos at> wrote:
> Hi all,
> I am wondering if there is any work on contracts for Python. I could
> only find PEP316, however, I am wondering if there is any official
> support for it already (tools I mean), and if it is or if it will be
> officially supported in any of the next releases of Python.

No, it's not officially supported and there are currently no plans to
support it, though as PEP 316 is Deferred and not Rejected, it's
theoretically possible that it could be Accepted and added to the
language some day.
At any rate, there are several third-party libraries available that
allow you to use Design by Contract in Python, albeit without
language-level support.
for a list


> Cheers,
> --
> Paulo Jorge Matos - pocmatos at
> Webpage:
> --

More information about the Python-list mailing list