jsoncanon

Typed Python implementation of JSON Canonicalization Scheme as described in RFC 8785. Currently lacks full floating point support


Keywords
JSON, RFC-8785, canonicalization, deterministic, serialization, hash
License
Apache-2.0
Install
pip install jsoncanon==0.2.3

Documentation

jsoncanon

Typed Python implementation of JSON Canonicalization Scheme as described in RFC 8785. The initial release (v0.2.x) is a partial release focused on the features needed by the Sequence Collections working group in the Global Alliance for Genomics and Health (GA4GH).

Usage

>>> import json
>>> from jsoncanon import canonicalize
>>>
>>> data = json.loads('{ "b": [1,3,7], "a": { "y": true, "x": null } }')
>>> canonicalize(data)
b'{"a":{"x":null,"y":true},"b":[1,3,7]}'

Releases

v0.2.0 - Initial release, supporting all data types except for floating point numbers v0.2.1 - Yanked due to incorrect link v0.2.2 - Initial release with updated project information