django-pghistory
django-pghistory copied to clipboard
datadump error: CommandError: Unable to serialize database: Must use .target() to target an object for event aggregation
Hello,
When using command manage.py dumpdata -o full_db.json, and i get the error "CommandError: Unable to serialize database: Must use .target() to target an object for event aggregation" I am unsure why this is happening and can't seem a way to fix it. if i exclude pghistory it works just fine.
The only way I can successfully dump the data is by excluding two PG history models:
manage.py dumpdata --exclude pghistory.context --exclude pghistory.aggregateevent
I'm going to find a way to address this in a later release. Thanks for letting me know! Will mark this as a bug for now
Found a workaround for this so that you don't always have to specify the exclude
argument via https://github.com/Opus10/django-pghistory/pull/61
Will close when the fix is deployed
fixed in version 2.4