{% extends "base.html" %} {% block title %}Sentinel — Run #{{ run.id }}{% endblock %} {% block content %} ← All Runs {% set counts = {'critical': grouped['critical']|length, 'high': grouped['high']|length, 'medium': grouped['medium']|length, 'low': grouped['low']|length} %}
Critical
{{ counts.critical }}
High
{{ counts.high }}
Medium
{{ counts.medium }}
Low
{{ counts.low }}
{% if filter_severity or filter_status or filter_detector %} Clear {% endif %}
{% if other_runs %}
{% endif %} {% if not findings %}

No findings

{% if filter_severity or filter_status or filter_detector %}No findings match the current filters.{% else %}This run produced no findings. The codebase looks clean!{% endif %}

{% else %}
{% for severity in ['critical', 'high', 'medium', 'low'] %} {% if grouped[severity] %}

{{ grouped[severity]|length }} finding{{ 's' if grouped[severity]|length != 1 else '' }}

{% for item in clustered[severity] %} {% if item.findings is defined %} {# This is a FindingCluster — render as collapsible group #}
{% if item.cluster_type == "pattern" %} 🔗 {{ item.findings|length }} related: {{ item.pattern_label }} {% else %} 📁 {{ item.findings|length }} findings in {{ item.common_path }} {% endif %}
{% for f in item.findings %}
{{ f.status.value }} {{ f.title }} {{ f.detector }} {% if f.file_path %} {{ f.file_path }}{% if f.line_start %}:{{ f.line_start }}{% endif %} {% endif %}
{% endfor %}
{% else %} {# This is a standalone Finding #}
{{ item.status.value }} {{ item.title }} {{ item.detector }} {% if item.file_path %} {{ item.file_path }}{% if item.line_start %}:{{ item.line_start }}{% endif %} {% endif %}
{% endif %} {% endfor %}
{% endif %} {% endfor %}
{% endif %} {% endblock %}