Jinja2 doesn’t support {% break %}
to exit a for-loop. The [for-loop’s documentation (Template Designer Documentation — Jinja Documentation (2.11.x)) states the following:
Unlike in Python, it’s not possible to break or continue in a loop. You can, however, filter the sequence during iteration, which allows you to skip items. The following example skips all the users which are hidden:
{% for user in users if not user.hidden %}
<li>{{ user.username|e }}</li>
{% endfor %}
Given that requirement, it poses a challenge to create an appropriate filter when you only have the period’s ‘start time’.