`request` parameter in Django – HTTPRequest or WSGIRequest

  Kiến thức lập trình

All of Django documentation says request is of type django.http.request.HTTPRequest. I use NGINX -> Waitress WSGI in my development, and I see see request is django.core.handlers.wsgi.WSGIRequest which inherits directly from HTTPRequest. I understand that Django must always run under WSGI, if so a request will always be WSGIRequest. So why does Django documentation always use HTTPRequest?

LEAVE A COMMENT