topmark.pipeline.pipelines¶
topmark / pipeline / pipelines
Named pipeline variants for TopMark (immutable, typed step sequences).
This module exposes immutable, typed step tuples and a registry mapping names
to pipelines. Pipelines are built from class-based steps that implement the
Step protocol.
Overview¶
PROBE: probe resolution onlySCAN: resolve → sniff → read → scanCHECK_RENDER: SCAN + build → renderCHECK(summary): CHECK_RENDER + compareCHECK_*(apply/patch): CHECK + update → (patch/write) variantsSTRIP(summary): SCAN + strip → compareSTRIP_*(apply/patch): STRIP + update → (patch/write) variants
Mermaid (orientation)¶
flowchart TD
subgraph Discovery
P[prober]
R[resolver]
S[sniffer]
D[reader]
N[scanner]
R --> S --> D --> N
end
subgraph Check
B[builder]
T[renderer]
C[comparer]
N --> B --> T --> C
end
subgraph Strip
X[stripper]
N --> X --> C
end
subgraph Mutations
U[updater]
H[patcher]
W[writer]
C --> U
U -->|patch| H
U -->|apply| W
end
Notes: * Pipelines are immutable (Final[tuple[Step, ...]]) and steps are instantiated objects (not functions). * Steps only write to the status axes they declare; outcome classification is derived centrally at the view/API layer.
PROBE_PIPELINE
module-attribute
¶
Probe file type and header processor resolution for a given file.
SCAN_PIPELINE
module-attribute
¶
Perform basic TopMark header scanning.
CHECK_RENDER_PIPELINE
module-attribute
¶
Render-only pipeline: resolves, sniffs, reads, scans, builds, and renders (no compare/update/patch).
CHECK_SUMMMARY_PIPELINE
module-attribute
¶
A lightweight pipeline that stops after comparison (no update/patch).
CHECK_PATCH_PIPELINE
module-attribute
¶
Only for generating unified diffs.
STRIP_PIPELINE
module-attribute
¶
NOTE: we do not run ComparerStep in a strip pipeline.
STRIP_PATCH_PIPELINE
module-attribute
¶
Only for generating unified diffs.
Pipeline ¶
Bases: tuple[Step[ProcessingContext], ...], Enum
Available execution pipelines for file processing, mapped to their step sequences.
steps
property
¶
Return the instantiated, ordered step sequence for this pipeline.
Returns:
| Type | Description |
|---|---|
Step[ProcessingContext]
|
tuple[Step, ...]: An immutable tuple of step instances that |
...
|
implement the |
tuple[Step[ProcessingContext], ...]
|
runner will invoke them as callables in order. |