-
Notifications
You must be signed in to change notification settings - Fork 6
Open
Description
Since keys in Python dicts are case sensitive, one can easily build a dict that has no valid HSD representation. Unfortunately, this is exactly what happens with the implementation in this repo:
>>> import hsd
>>> print(hsd.dumps({'key': 0.0, 'Key': 1.0}))
key = 0.0
Key = 1.0The preferable solution would be an exception from the serializer or a way to normalize a dict for HSD dumping.
Together with #6, the deserialization of the above HSD then yields {'key': [0.0, 1.0]}, so it cannot even be identified as invalid HSD.
Metadata
Metadata
Assignees
Labels
No labels