Skip to content

Cannot dump or load None with type NoneType. #63

@rhaps0dy

Description

@rhaps0dy

A bit silly, but a dataclass with a field of type None (or de/serializing something with NoneType itself) errors.

from databind.json import dump, load

load(None, None)
# NoMatchingConverter: no deserializer for `TypeHint(NoneType)` and payload of type `NoneType`

dump(None, None)
# NoMatchingConverter: no serializer for `TypeHint(NoneType)` and payload of type `NoneType`

Is this intentional or an oversight?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions