pub fn classify_exit(err: &Error) -> i32Expand description
Map an error to its process exit code per the ExitClass taxonomy.
Precedence (first match wins):
SchemaDriftErrordowncast →4.DataIntegrityErrororcrate::manifest::ManifestInconsistencydowncast →3.- otherwise, if [
crate::pipeline::retry::classify_error] says the error is transient →2. - otherwise →
1(generic).
§Why a string bridge for the aggregated run path
The single-export apply path returns the typed marker straight to main,
so the downcasts below fire directly. The multi-export run path used to
flatten per-export failures into a Vec<String> and re-raise a fresh
anyhow!, erasing the concrete type — which once forced a substring bridge
here. pipeline::run now carries a representative typed failure instead
(the most stop-worthy class among the failures), so the marker survives and
the downcasts work for rivet run too. Classification is therefore purely
type-driven: an un-typed data-integrity / drift failure classifies as
Generic on purpose — a visible signal that a marker was dropped upstream,
rather than being silently rescued by string matching.