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
When you attempt to e.g. insert a key in an ImmutableDict object, nothing happens - no error is thrown or anything. This means that bugs can pass undetected, and is unfortunate. For example, I was parsing an EDN file and forgot that the map within it would become immutable, treating it as a regular Python dict by attempting to insert keys, then ran into strange behavior because my insertions were being silently ignored. See below for an example:
import edn_format
d = edn_format.immutable_dict.ImmutableDict({"apple": 1, "pear": 2})
d["banana"] = 3 # does not throw an error, just is silently ignored
print(d["banana"]) # oops, KeyError
The text was updated successfully, but these errors were encountered:
Hi! Thanks for reporting the issue. I have not used or updated this library in a while, so I'm unlikely to look into this myself. I would encourage & welcome pull requests to fix this issue. Thanks.
When you attempt to e.g. insert a key in an ImmutableDict object, nothing happens - no error is thrown or anything. This means that bugs can pass undetected, and is unfortunate. For example, I was parsing an EDN file and forgot that the map within it would become immutable, treating it as a regular Python dict by attempting to insert keys, then ran into strange behavior because my insertions were being silently ignored. See below for an example:
The text was updated successfully, but these errors were encountered: