-
Notifications
You must be signed in to change notification settings - Fork 131
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Key ambiguity #73
Comments
Just to add, it also can't handle tuple keys |
@Jwink3101 thanks for the report & PR CC: @piskvorky how this should work? |
IIRC there was a long discussion about encoding keys, and in the end we decided against it. I don't remember the arguments any more, let me search through the issue history. |
In the changes of #74, byte/string keys are not modified. However, it appears as though the json encoding/decoding of the object may affect strings/bytes, especially on python2. I am not 100% sure of this behavior. But, it is worth noting again that this should not break any backwards compatibility as other keys are not touched. As I mentioned also in #74, one remedy in general is to instead use the pickle of the object as the key but I think that is risky since, in my quick testing, while the unpickled object between py2.7 and 3.6 pass an equality check, they are not the same (even if you base64 encode them) and therefore would not be found. |
@piskvorky through? |
Has anyone given this more consideration? |
When using integer keys, they are converted to strings. Therefore:
all refer to the same thing.
The text was updated successfully, but these errors were encountered: