Expand description
Window-scoped plugin host over the script runtime.
PluginHost owns its own ScriptManager instance — the same registry
type the per-tab script system uses, kept entirely separate so a plugin
can never be confused with a tab script. Discovery, per-kind process
lifecycle (one supervised process per declared kind, design D5), restart
supervision (manifest-declared mode — on_failure default, never,
always — under the host-owned delay and crash-loop cap), action
invocation, and the SetWidget text map all live here.
Land-disabled is structural (design D3): PluginHost::apply_enabled
receives only the enabled set, and discovery never spawns anything by
itself — a newly dropped-in plugin cannot run until the Settings layer
says so.
Structs§
- Enabled
Plugin - One plugin the host should be running (Task 4 maps config state to this).
- Plugin
Action Row - One command-palette entry contributed by an enabled action plugin.
- Plugin
Crash Cap - A plugin whose supervisor gave up: the entry crash-looped past
crate::restart::MAX_RESTART_ATTEMPTSinside the grace window (or the initial-spawn attempts did). Surfaced by the frontend as a crash-triage offer — same consent surface as a crashed pane. - Plugin
Host - Window-scoped plugin host: discovery cache, running processes, restart
supervision, and the last
SetWidgettext per plugin. - Warn
Once - Deduplicates a repeating fault warning to once per condition episode.