#[non_exhaustive]pub enum ParseError {
Show 17 variants
NotUtf8 {
what: &'static str,
nuls: usize,
},
NoInvocations,
UnbalancedQuoting {
line: String,
},
NoUnitData,
MalformedArray {
name: String,
detail: String,
},
TruncatedArray {
name: String,
},
BadUnitField {
entry: usize,
field: &'static str,
expected: &'static str,
},
NoSummaryTable,
MissingSummaryRow {
row: &'static str,
},
BadSummaryRow {
row: &'static str,
value: String,
expected: &'static str,
},
FreshUnits {
fresh: usize,
total: usize,
},
EmptyBuild,
DurationOutOfRange {
entry: usize,
seconds: f64,
},
UnmatchedUnits {
in_log: Vec<UnitDescription>,
in_report: Vec<UnitDescription>,
had_metadata: bool,
},
UnresolvedDependency {
consumer: Box<UnitDescription>,
dependency: String,
producer: String,
},
Metadata {
detail: String,
},
Graph(GraphError),
}Expand description
A build’s output that could not be turned into a graph, and why.
Every variant’s message states what to do next, because the usual cause is that the build the output came from was not the kind of build the analysis needs.
Variants (Non-exhaustive)§
This enum is marked as non-exhaustive
NotUtf8
The input holds NUL characters, so it is not the UTF-8 text Cargo wrote.
Fields
NoInvocations
The verbose log contained no compiler invocations at all.
UnbalancedQuoting
A Running line could not be split into arguments because a quote was left open.
NoUnitData
The timing report contained no UNIT_DATA array.
MalformedArray
A JavaScript array literal in the timing report was not valid JSON.
Fields
TruncatedArray
An array literal in the timing report was cut off before its closing bracket.
BadUnitField
A UNIT_DATA entry was missing a field, or the field had the wrong type.
Fields
NoSummaryTable
The timing report’s summary table was absent or unreadable.
MissingSummaryRow
The timing report’s summary table lacked a row the analysis needs.
BadSummaryRow
A summary row was present but did not hold the expected kind of value.
Fields
FreshUnits
The build reused cached units, so most of its weights are zero.
EmptyBuild
The build compiled nothing.
DurationOutOfRange
A duration in the timing report is not a duration.
UnmatchedUnits
The two inputs describe different sets of units.
Fields
in_log: Vec<UnitDescription>Units the verbose log has and the timing report does not.
in_report: Vec<UnitDescription>Units the timing report has and the verbose log does not.
UnresolvedDependency
A --extern names an artifact no invocation in this log produced.
Fields
consumer: Box<UnitDescription>The unit that named it, boxed so that a failure path does not widen every Result in
the crate.
Metadata
cargo metadata output could not be read.
Graph(GraphError)
The assembled graph was rejected by the core.
Trait Implementations§
Source§impl Clone for ParseError
impl Clone for ParseError
Source§impl Debug for ParseError
impl Debug for ParseError
Source§impl Display for ParseError
impl Display for ParseError
Source§impl Error for ParseError
impl Error for ParseError
Source§fn source(&self) -> Option<&(dyn Error + 'static)>
fn source(&self) -> Option<&(dyn Error + 'static)>
1.0.0 · Source§fn description(&self) -> &str
fn description(&self) -> &str
use the Display impl or to_string()