﻿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
24111	get_template dirs parameter doesn't work for loading of parent template	ThomasWaldmann	nobody	"Given: a directory ""templates"" with templates ""something.txt"" and ""base.txt"" (and something.txt extends base.txt) and this code:
{{{
def render_template(template, context):
    this_dir = os.path.abspath(os.path.dirname(__file__))
    template_dir = os.path.join(this_dir, 'templates')
    t = loader.get_template(template, dirs=[template_dir, ])
    return t.render(Context(context))

# finds and renders base.txt:
render_template(""base.txt"")

# finds and tries to render something.txt, but then fails to find base.txt:
render_template(""something.txt"")
}}}
I wanted to use this for django management commands which send emails, so I just wanted to load templates from a specific directory.
"	Bug	closed	Template system	1.7	Normal	wontfix			Unreviewed	0	0	0	0	0	0
