{% for n in notices %}
{{ n.text }}
{% endfor %}
{{ _('System:') }} {{ _('ENABLED') if enabled else _('DISABLED') }} {{ _('Loaded:') }} {{ loaded_count }} / {{ plugin_count }} {{ _('Active:') }} {{ active_count }} {{ _('Detectors:') }} {{ detector_count }} {{ _('Notifiers:') }} {{ notifier_count }} {{ _('Sources:') }} {{ source_count }}
{% if not enabled %}

{{ _('The plugin system is switched off; no plugin is loaded.') }} {{ _('Enable in config.toml:') }} [plugins] enabled = true

{% endif %} {% if plugins %} {% set type_labels = {'plugin': _('Plugin'), 'detector': _('Detector'), 'notifier': _('Notifier'), 'source': _('Source')} %}
{% for p in plugins %}
{{ p.name }} {% if p.loaded and p.type %}{{ type_labels.get(p.type | lower, p.type) }}{% endif %} {# Effective state of a loaded plugin. #} {% if p.loaded and p.state == 'active' %} {% if p.event_source %}{{ _('Running') }} {% else %}{{ _('Loaded') }}{% endif %} {% elif p.loaded and p.state == 'inactive' %} {{ _('Not running') }} {% elif p.loaded and p.state == 'unverified' %} {{ _('Run state unknown') }} {% endif %} {% if not p.loaded %} {% for reason in p.reasons %} {% if reason == 'system_off' %}{{ _('Plugin system off') }} {% elif reason == 'not_installed' %}{{ _('Not installed') }} {% elif reason == 'not_listed' %}{{ _('Not in builtin') }} {% elif reason == 'disabled' %}{{ _('Disabled in config') }} {% elif reason == 'not_registered' %}{{ _('Not registered') }} {% endif %} {% endfor %} {% endif %}
{% if p.loaded and p.events %}{{ p.events[:3]|join(' · ') }}{% if p.events|length > 3 %} +{{ p.events|length - 3 }}{% endif %}{% endif %} {% if p.loaded %}v{{ p.version }}{% else %}{{ _('Not loaded') }}{% endif %}
{# The section this plugin reads, and - only when it is loaded - the enabled value found there. The marker is what the tests (and grep) assert on: this element is the only place a status claim is made. #}
{{ _('Config section:') }} plugins.{{ p.section }} {%- if p.show_enabled %} · enabled = {{ 'true' if p.enabled else 'false' }}{% if not p.enabled_declared %} ({{ _('not set explicitly') }}){% endif %} {%- else %} · {{ _('enabled is not reported for a plugin that is not loaded') }}{% endif %}
{% if not p.loaded %}
{% for reason in p.reasons %} {% if reason == 'system_off' %}
{{ _('The [plugins] section is disabled, so nothing is loaded from builtin.') }}
{% elif reason == 'not_installed' %}
{{ _('Listed in config.toml, but this build has no implementation for it.') }}
{% elif reason == 'not_listed' %}
{{ _('This build can load it, but [plugins] builtin does not list it.') }}
{% elif reason == 'disabled' %}
{{ _('Installed but switched off in config.toml.') }}
{% elif reason == 'not_registered' %}
{{ _('Enabled and listed, but the plugin is not registered — check the startup log.') }}
{% endif %} {% endfor %} {% if p.snippet %}
{{ _('Add to config.toml:') }}
{{ p.snippet }}
{% endif %}
{% endif %} {% if p.installed %}
{% if p.enabled %} {% else %} {% endif %} {% if p.in_builtin %} {% else %} {% endif %} {% if p.guard_reason %} {{ _('Protected:') }} {{ p.guard_reason }} {% endif %}
{% endif %}
{% endfor %}
{% else %}

{{ _('No plugin is available in this build.') }}

{% endif %}