Skip to content

Serialite 0.3.1

Compare
Choose a tag to compare
@drhagen drhagen released this 13 Oct 00:50
· 11 commits to master since this release

This is the first public release of Serialite, a new serialization and deserialization library for Python. The core functionality is implemented and tested. The documentation is still lacking.

  • Serializer: The main abstract base class
  • Serializable: The abstract base class for classes that can serialize and deserialize instances of themselves
  • SerializableMixin: Provides an implementation for the Serializable interface given that the class attribute __fields_serializer__ is implemented as an instance of FieldsSerializer
  • AbstractSerializableMixin: Provides an implementation for the Serializable interface for a sealed class given that the class attribute __subclass_serializers__ is implemented
  • serializable: A decorator that provides an implementation of Serializable when applied to a dataclass
  • abstract_serializable: Provides an implementation of Serializable when applied to a sealed class, using the _type key as a discriminator and the names of the subclasses as the values
  • If installed, fastapi and pydantic are monkey patched to allow Serialite Serializables to work as Pydantic BaseModels in FastAPI endpoints