Fabians Bookmarks
  • Fabians Bookmarks
  • Tag cloud
  • Daily
  • RSS Feed
  • Login
Delete   Set public   Set private   Add tags   Delete tags
  Add tag   Cancel
  Delete tag   Cancel
17475 shaares · 14124 private links
Filters
Links per page
20 50 100

cattrs · PyPI

cattrs: Flexible Object Serialization and Validation

Because validation belongs to the edges.

cattrs is a Swiss Army knife for (un)structuring and validating data in Python. In practice, that means it converts unstructured dictionaries into proper classes and back, while validating their contents.
Example

cattrs works best with attrs classes, and dataclasses where simple (un-)structuring works out of the box, even for nested data, without polluting your data model with serialization details:

python attrs serialization validation library
September 18, 2024 at 1:09:56 PM GMT+2*
https://pypi.org/project/cattrs/
Filters
Links per page
20 50 100
By @fabian@floss.social · Powered by Shaarli
Fold Fold all Expand Expand all Are you sure you want to delete this link? Are you sure you want to delete this tag? The personal, minimalist, super-fast, database free, bookmarking service by the Shaarli community