Skip to content

Type hint for BaseModelAdminMixin.__init__ seems to be wrong #1483

@AppSynergy

Description

@AppSynergy

What version of Unfold are you using? >=0.60
What version of Django are you using? 5.2
What browser are you using? N/A
Did you checked changelog/commit history, if the bug is not already fixed? Yes
Did you searched other issues, if the bug is not already fixed? Yes
Did you checked documentation? No
Are you able to replicate the bug in the demo site? No
Repository with reproduced bug This one

Describe your issue

I think the type hint is wrong in BaseModelAdminMixin.__init__, unfold/mixins/base_model_admin.py.

https://github.com/unfoldadmin/django-unfold/blob/main/src/unfold/mixins/base_model_admin.py#L21C24-L21C43

Currently reads: model: models.Model. I think it should be: model: type[models.Model].

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions