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
If your model uses:
history = HistoricalRecords(
excluded_fields=["myfield"]
)
calling clean_duplicate_history will ending by an error:
simple_history/models.py", line 890, in diff_against
old_value = old_values[field]
KeyError: 'myfield'
why because in diff_against() :
included_fields = {
f.name for f in old_history.instance_type._meta.fields if f.editable
} ignores excluded_fields in the models declaration.
The text was updated successfully, but these errors were encountered:
Release 3.3.0 has now been uploaded to the Jazzband website, and we should only have to wait for one of the project leads or roadies to release it to PyPI 🙂 (see https://jazzband.co/about/releases)
If your model uses:
history = HistoricalRecords(
excluded_fields=["myfield"]
)
calling clean_duplicate_history will ending by an error:
simple_history/models.py", line 890, in diff_against
old_value = old_values[field]
KeyError: 'myfield'
why because in diff_against() :
included_fields = {
f.name for f in old_history.instance_type._meta.fields if f.editable
} ignores excluded_fields in the models declaration.
The text was updated successfully, but these errors were encountered: