Hello,

> I tend to warn people off thinking of template names as paths. It's
> an implementation detail that they are treated as such by the two
> default loaders.

> Requiring each loader to include an unique id with each template
> (even if it's just a full path) seems the easiest solution.

> Older 3rd party loaders which don't do this would not be able to
> participate, clearly.

The patch I'm working on relies on the loaders to do the skipping. That is,
code in ``django/template/loader.py`` does not know anything about template
skipping.

The benefit of that is that the default app and dirs loaders are the ones that
handle the skipping through the template's full path. Other loaders can handle
template skipping as they like or don't handle it at all.

Nearly the only change in ``django/template/loader.py`` would be to accept a
``skip_template`` parameter in ``find_template``, ``select_template`` and
``render_to_template`` funcs and pass that parameter on to the loaders.

Thanks for your concern!

Best wishes,

Unai Zalakain

Attachment: signature.asc
Description: PGP signature

Reply via email to