mitsuhiko/jinja2 — Issue #88: Accessing attributes that raises an exception
Author: Balon
Created: 2012-01-14 19:52:44+00:00
State: open

{{ user.userprofile }}

Let's assume that userprofile for given user does not exist. In Django templates, this would give us nothing. In Jinja, this gives me an exception.

I belive that the way how it works in jinja2 is correct and awesome, because it is very easy to catch bugs that would be difficult to find in standard django templates, but at the same time, it'd be nice to be able to test a variable if it raises an exception.