-
-
Notifications
You must be signed in to change notification settings - Fork 494
Closed
Labels
bugSomething isn't workingSomething isn't working
Description
Bug report
What's wrong
class ArticleDetailView(generic.DetailView):
model = Article
def get_queryset(self):
key = self.request.GET.get("draft_key")
PyCharm complains about the types here, even though mypy
doesn't.
Hinting request: WSGIRequest
solves the issue with PyCharm though.
How is that should be
There should not be any issue with the types. Is PyCharm wrong about complaining here? Is django-stubs wrong about typing request
with HttpRequest
and not something else like WSGIRequest
?
System information
- OS: macOS 12.1 (21C52)
python
version: Python 3.10.0django
version: 4.0mypy
version: mypy 0.930django-stubs
version: 1.9.0django-stubs-ext
version: 0.3.1
Metadata
Metadata
Assignees
Labels
bugSomething isn't workingSomething isn't working