Make generic RedirectView default to permanent=False
|Reported by:||wraus@…||Owned by:||Melevir|
|Has patch:||yes||Needs documentation:||yes|
|Needs tests:||no||Patch needs improvement:||yes|
Having been bitten by this, and seeing some other reports of it, it seems very unintuitive that RedirectView defaults to permanent.
Permanent redirects are cached on the browser, so the ramifications of accidentally making a permanent redirect away from an URL you are currently using or intend to use in the future are fairly serious. On the flip side, using a non-permanent redirect when you meant to use a permanent one has little real impact outside of taking slightly more time to redirect.
Having RedirectView default the permanent argument to False wouldn't actually break existing sites, since it will still redirect, so there's no serious backwards compatibility issues.
Change History (8)
comment:1 Changed 3 months ago by anonymous
- Needs documentation unset
- Needs tests unset
- Patch needs improvement unset
- Type changed from Uncategorized to Cleanup/optimization
comment:3 Changed 3 months ago by Melevir
- Owner changed from nobody to Melevir
- Status changed from new to assigned