title: Django dict key,value in for loop does not work
body: <p>I'm getting a little stuck on a Django problem where I can't access the values of a dict in a for loop. It works outside the for loop, just not inside.</p>
  
  <p>Am I missing the obvious here?</p>
  
  <p>Python:</p>
  
  <pre><code>err{}
  err['else'] = {'class': 'Low', 'txt': 'zero'}
  err['if'] = {'class': 'High', 'txt': 'one'}
  data = { 'errors': err }
  return render(request, 'index/error.html', data)
  </code></pre>
  
  <p>HTML template:</p>
  
  <pre><code>&lt;p&gt;{{ errors }}&lt;/p&gt;
  &lt;p&gt;{{ errors.if }}&lt;/p&gt;
  &lt;p&gt;{{ errors.if.class }}&lt;/p&gt;
  
  {% for error in errors %}
    &lt;div class="{{ error.class }}"&gt;&lt;p&gt;{{ error.txt }}&lt;/p&gt;&lt;/div&gt;
  {% endfor %}
  </code></pre>
  
  <p>The upper 3 lines are for code debugging and work just fine.
  The for loop doesn't produce any code.</p>
  
  <p>Best regards,
  LVX</p>