contracts. PyContracts is a Python package that allows to declare constraints on function parameters and return values. Contracts can be specified using Python3 annotations, or inside a docstring :type: and :rtype: tags. PyContracts supports a basic type system, variables binding, arithmetic constraints, and has several specialized contracts (notably for Numpy arrays), as well as an extension API.

github.com/braingram/contracts

Vaya's read on this project

Problem, audience, market, and the verdict — sign in to see it.

Updates

No recent activity.