﻿id	summary	reporter	owner	description	type	status	component	version	severity	resolution	keywords	cc	stage	has_patch	needs_docs	needs_tests	needs_better_patch	easy	ui_ux
31432	Conform to HTTP Status Code RFC's redirect classes.	Jacob Stöhr	nobody	"Hello,

while filing (and trying to fix) #31430 I noticed that the class `HttpResponsePermanentRedirect` in django.http.response has its `status_code` set to `301`.  

According to the `http` python module and more specifically RFC 7238 ([https://tools.ietf.org/html/rfc7238]) the name `PermanentRedirect` is used to describe the HTTP Status code `308`. `301` is called `MovedPermanently` according to  RFC 7231 ([https://tools.ietf.org/html/rfc7231#section-6.4.2]).

Therefore I propose to rename the class `HttpResponsePermanentRedirect` to `HttpResponseMovedPermanently` with a status code of `301` and to modify the existing class to have a status code of `308`. I am aware that this is backwards incompatible and will break 33 currently existing tests (I tested it real quick locally) and probably countless uses in tests. However I think it is important to comply with the official spec.

I would appreciate any feedback, I don't know who would be responsible for this kind of ticket so I cannot assign it directly.
If desired, I could probably come up with a patch or at least help with creating one.

Regards,
Jacob"	Cleanup/optimization	closed	HTTP handling	dev	Normal	wontfix			Unreviewed	0	0	0	0	0	0
