Moving the creation and setup of the DynamicFields in the HstoreModels to the __init__, instead of in the __class__._meta.dynamic_fields and refactoring all the code which was using the DynamicField.objects.filter.