Wrap history index signal with giant try: except:
This commit is contained in:
parent
bcb34cf63e
commit
4ff0900a20
|
@ -38,10 +38,11 @@ def post_create_historical_record_callback(
|
|||
using,
|
||||
**kwargs):
|
||||
|
||||
try:
|
||||
history_type = history_instance.get_history_type_display()
|
||||
object_name = instance.__class__.__name__
|
||||
|
||||
if object_name in ['User']: return
|
||||
if object_name in ['User', 'IPN']: return
|
||||
|
||||
if history_type == 'Changed':
|
||||
changes = history_instance.diff_against(history_instance.prev_record).changes
|
||||
|
@ -80,3 +81,10 @@ def post_create_historical_record_callback(
|
|||
old=change_old,
|
||||
new=change_new,
|
||||
)
|
||||
except BaseException as e:
|
||||
print('Problem creating history index: {} - {}'.format(e.__class__.__name__, e))
|
||||
print('sender', sender)
|
||||
print('instance', instance)
|
||||
print('history_instance', history_instance)
|
||||
print('history_user', history_user)
|
||||
print('using', using)
|
||||
|
|
Loading…
Reference in New Issue
Block a user