Skip to content

Releases: oxan/djangorestframework-dataclasses

djangorestframework-dataclasses v0.7

23 Oct 15:40

Choose a tag to compare

Breaking changes:

  • The validated_data representation now contains the rest_framework.fields.empty sentinel value for fields where no value was provided, instead of the default of the dataclass field. The value returned by save() is unchanged. This was necessary to support partial updates.

Features & fixes:

  • Improved Python 3.9 compatibility.
  • Support partial updates.
  • Support standard collection generics (PEP 585).
  • Support non-generic list and dict typehints.
  • Support final fields (PEP 591).
  • Support auto-generation for list or dictionaries of Any or variable type.
  • Set default max_digits and decimal_places for DecimalField.
  • Improved error message when automatic field type deduction fails.

djangorestframework-dataclasses v0.6

23 Oct 15:43

Choose a tag to compare

  • Rewrite to save() implementation to finally fix all issues with nested serializers.
  • Fix deserialization for fields using source option.
  • Fix explicit specification of a method in the fields option.

djangorestframework-dataclasses v0.5

23 Oct 15:43

Choose a tag to compare

  • Make optional fields on the dataclass optional on the serializer as well.
  • Fix (de-)serialization of dataclass lists specified with many=True.
  • Fix deserialization of nullable nested dataclasses.
  • Raise error when field is both declared and is present in extra_kwargs.
  • Raise error when non-existing fields are included in fields option.
  • Minor performance improvements.

djangorestframework-dataclasses v0.4

23 Oct 15:43

Choose a tag to compare

  • Automatically recognize Literal-typed fields (PEP 586).
  • Fix deserialization of dataclasses inside dictionaries.
  • Improve error message when encountering field with a special form type.

djangorestframework-dataclasses v0.3

23 Oct 15:42

Choose a tag to compare

  • Automatically recognize UUID fields.
  • Fix saving with nested dataclasses.

djangorestframework-dataclasses v0.2

23 Oct 15:42

Choose a tag to compare

  • Support arbitrary nesting of dictionaries and lists.
  • Support putting __all__ magic option in fields option on Meta class.

djangorestframework-dataclasses v0.1

23 Oct 15:41

Choose a tag to compare