Changelog¶
All notable changes to Duckdantic will be documented in this file.
The format is based on Keep a Changelog, and this project adheres to Semantic Versioning.
[Unreleased]¶
Added¶
- Duck API for ergonomic duck typing with Pydantic models
- Method signature checking with
MethodSpecandmethods_satisfy - ABC integration for
isinstance/issubclasssupport - Comprehensive trait composition with
union,intersect, andminus - Support for Pydantic v2 field aliases and validation
- Flexible type policies for customizable validation
- High-performance caching for field normalization
- Support for multiple object types (Pydantic, dataclasses, TypedDict, etc.)
Fixed¶
- Pydantic AliasChoices extraction for proper alias handling
- Hypothesis test generation to ensure unique field names in traits
Changed¶
- Improved Google-style docstrings throughout the codebase
- Enhanced error messages and detailed explanations
[0.1.0] - Initial Release¶
Added¶
- Initial implementation of structural typing for Python
- Basic trait specifications with
TraitSpecandFieldSpec - Core satisfaction checking with
satisfiesandexplain - Field normalization for various Python object types
- Type compatibility policies
- Trait registry for managing collections of traits