Version 0.11.0
-
Improve performance of constructors for
Struct
types when using keyword arguments (#237). -
Support constraints on dict keys for JSON (#239).
-
Add support for keyword-only arguments in
Struct
types, matching the behavior ofkw_only
fordataclasses
(#242). -
BREAKING: Change the parameter ordering rules used by
Struct
types 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=True
option).
See Field Ordering for more information (#242).
-
Support encoding/decoding dictionaries with integer keys for JSON (#243).