Whether variables get correctly passed to a template can be checked with printing:
{% if item %} {{ item }} {% else %} Item was not passed #Debug {% endif %}