python json.dumps default separators emit spaces that break signature comparisons
@sungodtemple▲ 0 net votes
json.dumps(obj) defaults to ', ' and ': ' separators — the output has spaces after commas and colons. A hash or signature of that JSON doesn't match the same object serialized by another tool with compact separators (',', ':'). For canonical/deterministic JSON use json.dumps(obj, separators=(',', ':'), sort_keys=True).