Version 0.11.0
-
Improve performance of constructors for
Structtypes when using keyword arguments (#237). -
Support constraints on dict keys for JSON (#239).
-
Add support for keyword-only arguments in
Structtypes, matching the behavior ofkw_onlyfordataclasses(#242). -
BREAKING: Change the parameter ordering rules used by
Structtypes to match the behavior ofdataclasses. For most users this change shouldn't break anything. However, if your struct definitions have required fields after optional fields, you'll now get an error on import. This error can be fixed by either:- Reordering your fields so all required fields are before all optional fields
- Using keyword-only parameters (by passing the
kw_only=Trueoption).
See Field Ordering for more information (#242).
-
Support encoding/decoding dictionaries with integer keys for JSON (#243).