Opened 9 years ago

Last modified 9 years ago

#25963 closed Bug

Docs for render_to_response and context_instance deprecation — at Initial Version

Reported by: Mark Tranchant Owned by: nobody
Component: Documentation Version: 1.9
Severity: Normal Keywords: render, render_to_response, context_instance, RequestContext
Cc: Triage Stage: Accepted
Has patch: yes Needs documentation: no
Needs tests: no Patch needs improvement: no
Easy pickings: yes UI/UX: no

Description

The render_to_response() documentation notes the deprecation of the context_instance argument:

"Deprecated since version 1.8: The context_instance argument is deprecated. Simply use context."

This advice is singularly unhelpful — it took me a fair amount of StackOverflow searching to work out what to do. I use the RequestContext to handle user messages and authorization, so it's essential for my project.

I'd suggest the note should read:

"Deprecated since version 1.8: The context_instance argument is deprecated. Simply use render() with the request as the first argument."

I don't know if that covers all use cases for the deprecation notice: if not, the original should be expanded to provide a better explanation. I've dragged my project along since 1.2 so am a fairly old hand yet it didn't make sense to me.

Change History (0)

Note: See TracTickets for help on using tickets.
Back to Top