Coverage for src/lexigram/admin/di/mount/context.py: 100%
15 statements
« prev ^ index » next coverage.py v7.15.4, created at 2026-08-21 14:56 +0800
« prev ^ index » next coverage.py v7.15.4, created at 2026-08-21 14:56 +0800
1"""Shared mutable context for the admin mount pipeline.
3Collects state produced by one mount phase and consumed by later phases so
4that the individual mount steps stay decoupled from each other.
5"""
7from __future__ import annotations
9from dataclasses import dataclass, field
10from typing import Any
13@dataclass
14class MountContext:
15 """Cross-phase state produced while mounting the admin panel."""
17 resources: dict[str, Any] = field(default_factory=dict)
18 controllers: list[Any] = field(default_factory=list)
19 middlewares: list[tuple[type, dict[str, Any]]] = field(default_factory=list)
20 contributors: list[Any] = field(default_factory=list)
21 settings_service: Any | None = None
22 contributor_registry: Any | None = None
23 cluster_registry: Any | None = None
24 nav_builder: Any | None = None
25 router: Any | None = None
26 admin_app: Any | None = None