1 Repo
Predefined validation functions for type checks, range constraints, regex matching, and length limits.
Distinct from Custom Attribute Rule Validations: Distinct from Custom Attribute Rule Validations: provides a library of built-in validators rather than user-defined validation functions.
Explore 1 awesome GitHub repository matching part of an awesome list · Built-in Validator Libraries. Refine with filters or upvote what's useful.
attrs is a Python library that automatically generates initialization, representation, equality, hashing, and ordering methods from declarative class attribute definitions. At its core, it provides a class decorator metaprogramming framework that intercepts class creation to rewrite the class body, producing dunder methods without manual boilerplate. The library includes a comprehensive attribute validation toolkit with built-in validators for type checks, range constraints, regex matching, length limits, and logical composition of validation rules. The library distinguishes itself through it
Ships a comprehensive set of built-in validators for type, range, regex, and length checks.