-
-
Notifications
You must be signed in to change notification settings - Fork 553
Model Field in type annotation runtime error #61
Copy link
Copy link
Closed
Description
Originally posted on the gitter:
I'm coming across this issue where I'm trying to use a
Fieldin a type annotation something like:Dict[Field, Any]If i use mypy on this with django-stubs enabled, i get this error message:
`Missing type parameters for generic type`
so then i change it to
Dict[Field[Any, Any], Any], and that fixes the problem in mypy, but at runtime, it fails:
`TypeError: 'type' object is not subscriptable`
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels