We'll have to think about how to fit the template debugging work I did
in new-admin into this as well
Ooh, this is nice -- I hadn't seen it before. I'll take a look at
your code and think about how the two could work together, but to
keep SVN conflicts to a minimum I won't actually integrate anything
into the trunk. At first glance it looks like the best thing to do
would be to make the attributes needed to render this exception into
fields on a TemplateError exception which the top-level error handler
would notice and treat differently than other error types.
One thing I haven't come up with a satisfactory answer to is where to
put the template for this, and what it should look like - at the
moment
it is in the admin app, and uses that layout too.
Maybe we need a "last chance" template loader that will always be
added
on the end of TEMPLATE_LOADERS?
Since these error pages need to be available when other things may be
broken -- even badly -- I'm routing around TEMPLATE_LOADERS and
loading the template files directly using Template(). This means
that you don't get to override them, but since they're error pages
that are only seen when DEBUG == True I don't see that that's a biggie.
Either way, I'm going to make a few tweaks and check this in later
today; feel free to critique my code :)
Jacob