grantmcconnaughey / django-field-history

A Django app to track changes to model fields.
BSD 3-Clause "New" or "Revised" License
314 stars 33 forks source link

UnicodeDecodeError with Python 2.7 and unicode string #15

Open slyapustin opened 8 years ago

slyapustin commented 8 years ago

This does not work, if object representation have type unicode:

return '{} field history for {}'.format(self.field_name, self.object)

fix for python 2.7:

return u'{} field history for {}'.format(self.field_name, self.object)

https://github.com/grantmcconnaughey/django-field-history/blob/master/field_history/models.py#L31

soloiago commented 7 years ago

Same problem here: Python 2.7.10, Django 1.11.5 I tried to fixed it (PR on going), but it seems that it fails with Python 3.2