nadzoring.core.models module

Shared, serializable diagnostic results and exit-code policy.

class nadzoring.core.models.CheckResult[source]

Bases: TypedDict

One diagnostic observation; errors are explicit even in machine output.

check: str
detail: str
error: str | None
status: Status
type nadzoring.core.models.Status = Literal['ok', 'warning', 'error', 'update-available']
nadzoring.core.models.exit_code(rows: list[CheckResult]) → int[source]

Return blocking errors before warnings, then update notifications.

nadzoring.core.models.result(check: str, detail: str, status: Status = 'ok') → CheckResult[source]

Build a diagnostic row with a structured expected-failure field.