Skip to content

default for tuples , time.struct_time, collections.counter, collections.ordereddict and collections.defaultdic ? #149

Description

@SmartAudioTools

Hi, I'm developing serializejson, a python library for fast serialization and deserialization of python objects in JSON designed as a safe, interoperable and human-readable drop-in replacement for the Python pickle package.

I use python-rapidjson in backend because it is the only one that is fast enough and has the sufficient API for serializejson needs.
Sadly python-rapidjson doesn't call default() method for tuples, time.struct_time, collections.counter, collections.ordereddict and collections.defaultdic. Python-rapidjson serialize them as a list or dictionary without any possibility to catch them with default().

Did I miss something? Would it be possible to add an option to call default for these objects?

Thanks !

Baptiste

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Fields

    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions