Coverage for ntnlog / ntn_levels.py: 100%
11 statements
« prev ^ index » next coverage.py v7.14.0, created at 2026-05-21 04:50 +0000
« prev ^ index » next coverage.py v7.14.0, created at 2026-05-21 04:50 +0000
1from enum import IntEnum
2from typing import Literal, TypeAlias
5class Level(IntEnum):
6 """
7 Severity levels for log entries, ordered from lowest to highest.
9 Members
10 -------
11 TRACE : 5 — Fine-grained diagnostic noise, below DEBUG.
12 DEBUG : 10 — Development-time diagnostics.
13 INFO : 20 — Normal operational messages.
14 WARN : 30 — Something unexpected but recoverable.
15 ERROR : 40 — A failure that needs attention.
16 CRITICAL : 50 — A severe failure; the process may not be able to continue.
17 """
19 TRACE = 5
20 DEBUG = 10
21 INFO = 20
22 WARNING = 30
23 ERROR = 40
24 CRITICAL = 50
27LevelStr: TypeAlias = Literal["TRACE", "DEBUG", "INFO", "WARN", "ERROR", "CRITICAL"]
28LevelLike: TypeAlias = Level | LevelStr