﻿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
9873	Template reuse is worthless(when inheretiance or inclusion involved) because parent templates get re-compiled every time	novoya	nobody	"The following view module fails to make good reuse to the template
For each new request, all inherited/included templates will be recreated and compiled
{{{
tpl = loader.get_template('mytemplate.html')

def view_func1(request):
     '''
        Any inherited templates from tpl
        will created and recompiled again and again
     '''
     return HttpResponse(tpl.render(context)) 
}}}
Attached a very simple patch to solve the problem:
1.Simple template caching in the django.template.loader
2.Minimum change in django.template.loader_tags
"		closed	Template system	dev		duplicate	template cache		Unreviewed	0	0	0	0	0	0
