Check
check
Structured diagnostics produced by the read-only batch_edit checks.
A :class:CheckDiagnostic is the single currency of the static-check layer:
it locates a finding (op_index + file), qualifies it (severity +
stable code) and explains it (message + actionable hint). The
model carries no I/O and no rendering concern.
Severity = Literal['error', 'warning']
module-attribute
Closed set of diagnostic severities.
CheckDiagnostic
Bases: BaseModel
A single static-check finding on a batch operation.
Attributes:
| Name | Type | Description |
|---|---|---|
op_index |
int
|
0-indexed position of the offending operation in the batch. |
file |
str
|
Relative path targeted by that operation. |
severity |
Severity
|
|
code |
str
|
Stable machine-readable identifier (e.g. |
message |
str
|
Human-readable explanation of what was found. |
hint |
str
|
Actionable remediation advice. |
edit_index |
int | None
|
0-indexed position of the offending edit inside that
operation, or |
anchor_excerpt |
str | None
|
Bounded single-line excerpt of the offending anchor,
or |
Source code in packages/axm-edit/src/axm_edit/models/check.py
PreflightReport
Bases: BaseModel
A partitioned preflight verdict over a single batch.
Attributes:
| Name | Type | Description |
|---|---|---|
diagnostics |
list[CheckDiagnostic]
|
Every diagnostic collected, in the order given. |
errors |
list[CheckDiagnostic]
|
The blocking subset, in input order. |
warnings |
list[CheckDiagnostic]
|
The non-blocking subset, in input order. |
blocking |
bool
|
True iff at least one diagnostic blocks the batch. |