title: Wagtail / Django ListBlock Behavior
body: <p>I am facing a wired situation, using wagtail.</p>
  
  <p>My Models :</p>
  
  <pre><code>class SlideBlock(blocks.StructBlock):
      image = ImageChooserBlock()
      caption = blocks.CharBlock(required=False)
  
  class Meta:
      template = 'home/blocks/carousel.html'
  
  class HomePageIndex(Page):
      body = StreamField([
          ('head', blocks.TextBlock(classname="full title")),
          ('text', blocks.RichTextBlock()),
          ('html', blocks.RawHTMLBlock()),
          ('slider', blocks.ListBlock(SlideBlock()))
      ], blank=True)
  
      content_panels = Page.content_panels + [
          StreamFieldPanel('body'),
      ]
  
      # parent_page_types = []
      subpage_types = ['home.HomePageIndex',
                       'blog.BlogPageIndex',
                       'blog.BlogTagPageIndex']
  </code></pre>
  
  <p>My Template (MAIN) :</p>
  
  <pre><code>{% with blocks=self.body %}
  
  {% for block in blocks %}
  
      &lt;section&gt;
          {% elif block.block_type == 'slider' %}
              in
              &lt;!-- Gate to an nested template --&gt;
              {% include_block block %}
              out
          {% else %}
              block-type not supported
          {% endif %}
      &lt;/section&gt;
  
  {% endfor %}
  &lt;/article&gt;
  {% endwith %}
  </code></pre>
  
  <p>My Template (nested) :</p>
  
  <pre><code>&lt;div&gt;
      &lt;div&gt;
  
          {% for x in block.value %}
  
              &lt;div class="carousel-item"&gt;
                  {% image x.image max-1920x1080 class="d-block w-100" alt="Slide" %}
              &lt;/div&gt;
          {% endfor %}
      &lt;/div&gt;
  &lt;/div&gt;
  </code></pre>
  
  <p>Inside my database i use some test-data for testing reasons... But for some weired reason the nested template is called, as much data is inside my database. So i am not able to iterate over the ListBlock propertly. The output of the given example produces wired repeating outputs...</p>
  
  <p>What did i miss / oversee?</p>