diff --git a/django/db/models/fields/__init__.py b/django/db/models/fields/__init__.py index 4640eb3238..3c58873035 100644 --- a/django/db/models/fields/__init__.py +++ b/django/db/models/fields/__init__.py @@ -459,6 +459,9 @@ class AutoField(Field): kwargs['blank'] = True Field.__init__(self, *args, **kwargs) + def get_internal_type(self): + return "AutoField" + def to_python(self, value): if value is None: return value