kezabelle / django-shouty-templates

A monkeypatch to make Django error super loudly about invalid template access
BSD 2-Clause "Simplified" License
7 stars 0 forks source link

Django's ability to render the right position in code is often wrong, output the template name? #3

Closed kezabelle closed 4 years ago

kezabelle commented 4 years ago

For example, on a 2.2 project right now, if I output {{ wheeeeeeeeee }} in a sub template, it's just showing me the first 10 lines of the base template from which everything extends.

Buuuuuuuuut, the context in new_resolve_lookup may well have .template which might have .origin.name on it, which could be used in the exception message to say which template actually died.