# oscard-06/fenn-plugin_installer architecture

> Architecture diagram of the GitHub repository oscard-06/fenn-plugin_installer, generated by GitDiagram from its file tree, README and a sample of source files (last updated 2026-11-27). It is an AI-made overview: check details against the source.

- Interactive diagram: https://gitdiagram.com/oscard-06/fenn-plugin_installer
- Repository: https://github.com/oscard-06/fenn-plugin_installer

## Overview

Plugin Installer is a Fenn desktop plugin for discovering live marketplace plugins, inspecting their metadata, matching local installs and updates, and launching Fenn’s installer. The main workflow runs from Fenn events through the controller and background catalogue/detail fetches, into rendered Notch and Taskbar surfaces; install actions open Fenn deep links. The graph preserves the documented settings, local scanning, avatar caching, and schema-safety capabilities. Some UI and controller internals were only partially excerpted, so uncertain connections are omitted.

Main entry points: [`main.py`](https://github.com/oscard-06/fenn-plugin_installer/blob/main/main.py) (Event coordinator), [`plugin_installer/state.py`](https://github.com/oscard-06/fenn-plugin_installer/blob/main/plugin_installer/state.py) (Store controller), [`fenn.py`](https://github.com/oscard-06/fenn-plugin_installer/blob/main/fenn.py) (Fenn plugin API), [`plugin_installer/marketplace.py`](https://github.com/oscard-06/fenn-plugin_installer/blob/main/plugin_installer/marketplace.py) (Live catalogue client)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_runtime["Plugin runtime"]
  node_main["Event coordinator<br/>[main.py]"]
  node_fenn_helper["Fenn plugin API<br/>[fenn.py]"]
end

subgraph group_marketplace["Marketplace data"]
  node_marketplace_client["Live catalogue client<br/>[marketplace.py]"]
  node_local_scan["Installed plugin scan<br/>[marketplace.py]"]
  node_avatar_cache[("Avatar cache<br/>[marketplace.py]")]
end

subgraph group_domain["Plugin domain"]
  node_controller["Store controller<br/>[state.py]"]
  node_models["Models and validation<br/>[models.py]"]
  node_settings[("Settings and catalogue cache<br/>[state.py]")]
  node_snapshot["Store snapshot<br/>[models.py]"]
  node_install_link["Fenn install link<br/>[models.py]"]
end

subgraph group_surfaces["Fenn surfaces"]
  node_tile["Notch tiles<br/>[views.py]"]
  node_notch_page["Notch tabs and detail<br/>[views.py]"]
  node_taskbar["Taskbar pill and preview<br/>[views.py]"]
  node_popup["Taskbar popup<br/>[views.py]"]
end

node_user(("Fenn user"))
node_host(("Fenn host"))
node_catalogue_service[("Convex marketplace")]
node_plugin_files[("Plugin directories")]

node_user -->|"uses"| node_host
node_host -->|"starts plugin"| node_main
node_main -->|"registers handlers"| node_fenn_helper
node_main -->|"creates and queries"| node_controller
node_main -->|"fetches catalogue and detail"| node_marketplace_client
node_marketplace_client -->|"queries live API"| node_catalogue_service
node_marketplace_client -->|"parses responses"| node_models
node_controller -->|"scans installs"| node_local_scan
node_local_scan -->|"reads manifests"| node_plugin_files
node_controller -->|"loads and saves"| node_settings
node_controller -->|"uses cached avatars"| node_avatar_cache
node_main -->|"fetches avatars"| node_avatar_cache
node_controller -->|"uses domain models"| node_models
node_controller -->|"builds snapshot"| node_snapshot
node_main -->|"requests snapshot"| node_snapshot
node_main -->|"renders tile"| node_tile
node_main -->|"renders page"| node_notch_page
node_main -->|"renders bar and preview"| node_taskbar
node_main -->|"renders popup"| node_popup
node_tile -->|"builds Fenn UI"| node_fenn_helper
node_notch_page -->|"builds Fenn UI"| node_fenn_helper
node_taskbar -->|"builds Fenn UI"| node_fenn_helper
node_popup -->|"builds Fenn UI"| node_fenn_helper
node_fenn_helper -->|"sends views and receives events"| node_host
node_main -->|"requests install URI"| node_controller
node_controller -->|"builds install link"| node_install_link
node_main -->|"opens install link"| node_host

click node_main "https://github.com/oscard-06/fenn-plugin_installer/blob/main/main.py"
click node_fenn_helper "https://github.com/oscard-06/fenn-plugin_installer/blob/main/fenn.py"
click node_controller "https://github.com/oscard-06/fenn-plugin_installer/blob/main/plugin_installer/state.py"
click node_models "https://github.com/oscard-06/fenn-plugin_installer/blob/main/plugin_installer/models.py"
click node_marketplace_client "https://github.com/oscard-06/fenn-plugin_installer/blob/main/plugin_installer/marketplace.py"
click node_local_scan "https://github.com/oscard-06/fenn-plugin_installer/blob/main/plugin_installer/marketplace.py"
click node_avatar_cache "https://github.com/oscard-06/fenn-plugin_installer/blob/main/plugin_installer/marketplace.py"
click node_settings "https://github.com/oscard-06/fenn-plugin_installer/blob/main/plugin_installer/state.py"
click node_snapshot "https://github.com/oscard-06/fenn-plugin_installer/blob/main/plugin_installer/models.py"
click node_tile "https://github.com/oscard-06/fenn-plugin_installer/blob/main/plugin_installer/views.py"
click node_notch_page "https://github.com/oscard-06/fenn-plugin_installer/blob/main/plugin_installer/views.py"
click node_taskbar "https://github.com/oscard-06/fenn-plugin_installer/blob/main/plugin_installer/views.py"
click node_popup "https://github.com/oscard-06/fenn-plugin_installer/blob/main/plugin_installer/views.py"
click node_install_link "https://github.com/oscard-06/fenn-plugin_installer/blob/main/plugin_installer/models.py"

classDef toneNeutral fill:#f8fafc,stroke:#334155,stroke-width:1.5px,color:#0f172a
classDef toneBlue fill:#dbeafe,stroke:#2563eb,stroke-width:1.5px,color:#172554
classDef toneAmber fill:#fef3c7,stroke:#d97706,stroke-width:1.5px,color:#78350f
classDef toneMint fill:#dcfce7,stroke:#16a34a,stroke-width:1.5px,color:#14532d
classDef toneRose fill:#ffe4e6,stroke:#e11d48,stroke-width:1.5px,color:#881337
classDef toneIndigo fill:#e0e7ff,stroke:#4f46e5,stroke-width:1.5px,color:#312e81
classDef toneTeal fill:#ccfbf1,stroke:#0f766e,stroke-width:1.5px,color:#134e4a
class node_main,node_fenn_helper,node_user toneBlue
class node_marketplace_client,node_local_scan,node_avatar_cache,node_catalogue_service,node_plugin_files toneAmber
class node_controller,node_models,node_settings,node_snapshot,node_install_link toneMint
class node_tile,node_notch_page,node_taskbar,node_popup toneRose
class node_host toneIndigo
```

## Components

### Plugin runtime

- [Event coordinator](https://github.com/oscard-06/fenn-plugin_installer/blob/main/main.py): `main.py`
- [Fenn plugin API](https://github.com/oscard-06/fenn-plugin_installer/blob/main/fenn.py): `fenn.py`

### Marketplace data

- [Live catalogue client](https://github.com/oscard-06/fenn-plugin_installer/blob/main/plugin_installer/marketplace.py): `plugin_installer/marketplace.py`
- [Installed plugin scan](https://github.com/oscard-06/fenn-plugin_installer/blob/main/plugin_installer/marketplace.py): `plugin_installer/marketplace.py`
- [Avatar cache](https://github.com/oscard-06/fenn-plugin_installer/blob/main/plugin_installer/marketplace.py): `plugin_installer/marketplace.py`

### Plugin domain

- [Store controller](https://github.com/oscard-06/fenn-plugin_installer/blob/main/plugin_installer/state.py): `plugin_installer/state.py`
- [Models and validation](https://github.com/oscard-06/fenn-plugin_installer/blob/main/plugin_installer/models.py): `plugin_installer/models.py`
- [Settings and catalogue cache](https://github.com/oscard-06/fenn-plugin_installer/blob/main/plugin_installer/state.py): `plugin_installer/state.py`
- [Store snapshot](https://github.com/oscard-06/fenn-plugin_installer/blob/main/plugin_installer/models.py): `plugin_installer/models.py`
- [Fenn install link](https://github.com/oscard-06/fenn-plugin_installer/blob/main/plugin_installer/models.py): `plugin_installer/models.py`

### Fenn surfaces

- [Notch tiles](https://github.com/oscard-06/fenn-plugin_installer/blob/main/plugin_installer/views.py): `plugin_installer/views.py`
- [Notch tabs and detail](https://github.com/oscard-06/fenn-plugin_installer/blob/main/plugin_installer/views.py): `plugin_installer/views.py`
- [Taskbar pill and preview](https://github.com/oscard-06/fenn-plugin_installer/blob/main/plugin_installer/views.py): `plugin_installer/views.py`
- [Taskbar popup](https://github.com/oscard-06/fenn-plugin_installer/blob/main/plugin_installer/views.py): `plugin_installer/views.py`

### Other components

- **Fenn user**
- **Fenn host**
- **Convex marketplace**
- **Plugin directories**

## Connections

- Fenn user → Fenn host: uses (evidence: `README.md`)
- Fenn host → Event coordinator: starts plugin (evidence: `README.md`)
- Event coordinator → Fenn plugin API: registers handlers (evidence: `main.py`)
- Event coordinator → Store controller: creates and queries (evidence: `main.py`)
- Event coordinator → Live catalogue client: fetches catalogue and detail (evidence: `main.py`)
- Live catalogue client → Convex marketplace: queries live API (evidence: `README.md`)
- Live catalogue client → Models and validation: parses responses (evidence: `plugin_installer/marketplace.py`)
- Store controller → Installed plugin scan: scans installs (evidence: `plugin_installer/state.py`)
- Installed plugin scan → Plugin directories: reads manifests (evidence: `README.md`)
- Store controller → Settings and catalogue cache: loads and saves (evidence: `plugin_installer/state.py`)
- Store controller → Avatar cache: uses cached avatars (evidence: `plugin_installer/state.py`)
- Event coordinator → Avatar cache: fetches avatars (evidence: `main.py`)
- Store controller → Models and validation: uses domain models (evidence: `plugin_installer/state.py`)
- Store controller → Store snapshot: builds snapshot (evidence: `plugin_installer/state.py`)
- Event coordinator → Store snapshot: requests snapshot (evidence: `main.py`)
- Event coordinator → Notch tiles: renders tile (evidence: `main.py`)
- Event coordinator → Notch tabs and detail: renders page (evidence: `main.py`)
- Event coordinator → Taskbar pill and preview: renders bar and preview (evidence: `main.py`)
- Event coordinator → Taskbar popup: renders popup (evidence: `main.py`)
- Notch tiles → Fenn plugin API: builds Fenn UI (evidence: `plugin_installer/views.py`)
- Notch tabs and detail → Fenn plugin API: builds Fenn UI (evidence: `plugin_installer/views.py`)
- Taskbar pill and preview → Fenn plugin API: builds Fenn UI (evidence: `plugin_installer/views.py`)
- Taskbar popup → Fenn plugin API: builds Fenn UI (evidence: `plugin_installer/views.py`)
- Fenn plugin API → Fenn host: sends views and receives events (evidence: `fenn.py`)
- Event coordinator → Store controller: requests install URI (evidence: `main.py`)
- Store controller → Fenn install link: builds install link (evidence: `plugin_installer/models.py`)
- Event coordinator → Fenn host: opens install link (evidence: `main.py`)
