django-encrypted-id
django-encrypted-id copied to clipboard
Python 2.7.3. error
Hey :) I noticed that when get_by_ekey_or_404()
is used with Python 2.7.3 it fails on struct.unpack()
method, probably because of from __future__ import unicode_literals
. We had your library on production, so I had to apply a dirty monkeypatch and I'm not actually sure if this will fix the bug, but you might want to look into this :) This is the small code change: https://github.com/Eimis/django-encrypted-id/commit/9952f23eac048b2ea6a9157a1d08d4742274ed14
:-)
Thanks for reporting and fix. Will implement it and release soon.
@jatinderjit please do this.
@Eimis I'm unable to reproduce the issue. Though the string formats we used struct.pack
and struct.unpack
inconsistently, but the struct
functions seem to handle them regardless of the format (tested in Python 2.7.3 and Python 3.5.2)
Could you provide a specific case where you faced this issue?