A Python data validation library focused on simplicity, complex data structures, and useful error messages.
Voluptuous is a Python library for validating data structures, particularly data coming into Python as JSON, YAML, or similar formats. It allows developers to define schemas that describe expected data shapes and constraints, ensuring data integrity and providing meaningful error messages when validation fails.
Python developers building APIs, data processing pipelines, or applications that consume structured data from external sources like web APIs or configuration files.
Developers choose Voluptuous for its simplicity, intuitive schema definitions using native Python data structures, and excellent support for complex nested data without the overhead of more verbose validation frameworks.
CONTRIBUTIONS ONLY: Voluptuous, despite the name, is a Python data validation library.
Open-Awesome is built by the community, for the community. Submit a project, suggest an awesome list, or help improve the catalog on GitHub.
Schemas use native Python data structures like dictionaries and lists, making them easy to read and write without learning a new DSL or subclassing.
Validators are plain Python callables, allowing custom validation logic with simple functions, as shown in examples using datetime or custom checks.
Raises Invalid exceptions with descriptive messages and paths (e.g., @ data['key']), helping pinpoint validation failures in complex data structures.
Handles nested dictionaries, lists, and recursive schemas with Self, providing consistency across simple and complex validation scenarios.
The project is in 'CONTRIBUTIONS ONLY' mode with the author no longer using it, leading to potential stagnation in bug fixes and new features.
Lacks built-in support for Python type hints, dataclasses, or async validation, which are common in newer libraries like Pydantic.
For basic validation, schema definitions can be more verbose compared to alternatives that use decorators or concise type annotations.