Audience
Anyone seeking a solution for labeling objects as conforming to a given API or contract
About zope.interface
This package is intended to be independently reusable in any Python project. It is maintained by the Zope Toolkit project. This package provides an implementation of “object interfaces” for Python. Interfaces are a mechanism for labeling objects as conforming to a given API or contract. So, this package can be considered as an implementation of the Design By Contract methodology support in Python. Interfaces are objects that specify (document) the external behavior of objects that “provide” them. An interface specifies behavior through informal documentation in a doc string, attribute definitions, and invariants, which are conditions that must hold for objects that provide the interface. Attribute definitions specify specific attributes. They define the attribute name and provide documentation and constraints of attribute values. Attribute definitions can take a number of forms.