diff --git a/django-stubs/contrib/contenttypes/fields.pyi b/django-stubs/contrib/contenttypes/fields.pyi index 309208e9e..0e30ab039 100644 --- a/django-stubs/contrib/contenttypes/fields.pyi +++ b/django-stubs/contrib/contenttypes/fields.pyi @@ -44,11 +44,14 @@ class GenericForeignKey(FieldCacheMixin): def check(self, **kwargs: Any) -> list[CheckMessage]: ... def get_cache_name(self) -> str: ... def get_content_type( - self, obj: Model | None = ..., id: int | None = ..., using: str | None = ... + self, obj: Model | None = ..., id: int | None = ..., using: str | None = ..., model: type[Model] | None = ... ) -> ContentType: ... def get_prefetch_queryset( self, instances: list[Model] | QuerySet, queryset: QuerySet | None = ... ) -> tuple[list[Model], Callable, Callable, bool, str, bool]: ... + def get_prefetch_querysets( + self, instances: list[Model] | QuerySet, querysets: list[QuerySet] | None = ... + ) -> tuple[list[Model], Callable, Callable, bool, str, bool]: ... def __get__(self, instance: Model | None, cls: type[Model] | None = ...) -> Any | None: ... def __set__(self, instance: Model, value: Any | None) -> None: ... diff --git a/scripts/stubtest/allowlist_todo_django50.txt b/scripts/stubtest/allowlist_todo_django50.txt index eaf277ec3..4d17ad493 100644 --- a/scripts/stubtest/allowlist_todo_django50.txt +++ b/scripts/stubtest/allowlist_todo_django50.txt @@ -2,8 +2,6 @@ # Only discrepancies that appeared after Django 4.2 -> 5.0 update. # Unsorted: there are real problems and things we can really ignore. -django.contrib.contenttypes.fields.GenericForeignKey.get_content_type -django.contrib.contenttypes.fields.GenericForeignKey.get_prefetch_querysets django.contrib.gis.db.models.Case.allowed_default django.contrib.gis.db.models.ExpressionWrapper.allowed_default django.contrib.gis.db.models.F.allowed_default