Hi Adam,
Thanks for your reply.
I agree, I think that would be a nice addition. The issue we’ll have is that the current naming of the HttpResponsePermanentRedirect (301 Moved Permanently) will be confusing.
existing
- HttpResponsePermanentRedirect (301 Moved Permanently) => should probably be HttpResponseMovedPermanently
- HttpResponseRedirect (302 Found) => should probably be HttpResponseFound
new additions
- HttpResponseTemporaryRedirect (307 Temporary Redirect) => probably ok with the existing naming for 302
- ? (308 Permanent Redirect) ==> naming conflict with the existing 301, HttpResponsePermanentRedirect308? HttpResponsePermanentRedirection? HttpResponsePermanentlyRedirected? … not super convinced by these suggestions. What do you think?
I could add the new responses and mention them in the documentation here with the recommendation
https://docs.djangoproject.com/en/2.1/ref/request-response/#httpresponse-subclassesWe could also mention the 308 redirect at the end of the class docstring here
https://docs.djangoproject.com/en/2.1/_modules/django/middleware/common/Cheers,
Matthieu