'Django method for validating uniqueness constraints.
We can have uniqueness constraints that can\'t be expressed as a tuple of fields,
so need to override this to implement.
We can also have "soft" uniqueness constraints that may not be used when importing,
so we add that parameter here.
Also, when model is deleted, don\'t validate its foreign keys anymore--they may fail.'

def full_clean(self, exclude=None, imported=False):

    exclude = (exclude or [])
    if imported:
        exclude = list(set((tuple(exclude) + self._import_excluded_validation_fields)))
    if self.deleted:
        exclude = (exclude + [f.name for f in self._meta.fields if isinstance(f, models.ForeignKey)])
    return super(SyncedModel, self).full_clean(exclude=exclude)
