Coverage for src / lexigram / contracts / data / relation_loader.py: 0%
5 statements
« prev ^ index » next coverage.py v7.13.5, created at 2026-08-15 18:57 +0800
« prev ^ index » next coverage.py v7.13.5, created at 2026-08-15 18:57 +0800
1from __future__ import annotations
3from typing import Any, Protocol, runtime_checkable
6@runtime_checkable
7class RelationLoaderProtocol(Protocol):
8 """Protocol for loading related data."""
10 async def load_relations(
11 self,
12 records: list[dict[str, Any]],
13 relations: list[str],
14 ) -> list[dict[str, Any]]: ...
16 async def get_relation_options(
17 self,
18 relation_name: str,
19 filters: dict[str, Any] | None = None,
20 ) -> list[dict[str, Any]]: ...
23__all__ = ["RelationLoaderProtocol"]