You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
To support serializing arbitrary objects, it'd be useful to add a default callback (mirroring the option in json.dumps, orjson.dumps, ...). If provided, this would be called on unsupported objects, and would be expected to return a supported object.
defdefault(obj: Any) ->Any: # where the out Any is a supported type
...
This would allow for converting unsupported types into supported types lazily, as well as fancier things like serializing unsupported large objects out-of-band.
This has now been released as part of 0.2.0, and is available on PyPI. Please let me know how it works out for you, or if you have any further requests/questions.
Activity
jcrist commentedon Feb 25, 2021
cc @jakirkham, @madsbk, @quasiben, @mrocklin.
jcrist commentedon Feb 25, 2021
See #21.
jcrist commentedon Feb 25, 2021
This has now been released as part of 0.2.0, and is available on PyPI. Please let me know how it works out for you, or if you have any further requests/questions.
Fix `Meta(pattern=..)` memory leak / corruption (msgspec#1256)