def validate_instance(self, instance, import_validation_errors=None, validate_unique=True):
if import_validation_errors is None:<EOL><INDENT>errors = {}<EOL><DEDENT>else:<EOL><INDENT>errors = import_validation_errors.copy()<EOL><DEDENT>if self._meta.clean_model_instances:<EOL><INDENT>try:<EOL><INDENT>instance.full_clean(<EOL>exclude=errors.keys(),<EOL>validate_unique=validate_unique,<EOL>)<EOL><DEDENT>except ValidationError as e:<EOL><INDENT>errors = e.update_error_dict(errors)<EOL><DEDENT><DEDENT>if errors:<EOL><INDENT>raise ValidationError(errors)<EOL><DEDENT>
Takes any validation errors that were raised by
:meth:`~import_export.resources.Resource.import_obj`, and combines them
with validation errors raised by the instance's ``full_clean()``
method. The combined errors are then re-raised as single, multi-field
ValidationError.

If the ``clean_model_instances`` option is False, the instances's
``full_clean()`` method is not called, and only the errors raised by
``import_obj()`` are re-raised.