﻿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
29597	AttributeError when django.template.context_processors.debug is invoked with null request	Eric Hellman	nobody	"When the DjangoTemplates engine is used to render a template with a null request (for example, when used in render_to_string to render an email body) this line:

{{{
    if settings.DEBUG and request.META.get('REMOTE_ADDR') in settings.INTERNAL_IPS:
}}}

raises an AttributeError: 'dict' object has no attribute 'META'
This should be replaced by:
{{{
    if settings.DEBUG and request and  request.META.get('REMOTE_ADDR') in settings.INTERNAL_IPS:
}}}

otherwise, the debug context processor cannot be use for systems that render templates without a request."	Bug	closed	Template system	dev	Normal	invalid			Unreviewed	0	0	0	0	1	0
