pub struct ScanReport {
pub merges_seen: usize,
pub merges_scanned: usize,
pub skipped_octopus: usize,
pub skipped_no_base: usize,
pub paths_scanned: usize,
pub skipped_binary: usize,
pub skipped_large: usize,
pub lines_relocated: usize,
pub paths_all_relocated: usize,
pub lines_surviving_elsewhere: usize,
pub findings_all_surviving: usize,
pub findings: Vec<Finding>,
}Expand description
What one repository’s scan counted.
Every skip is counted rather than dropped: a rate whose denominator quietly excluded the hard cases is the failure mode this whole measurement exists to avoid.
Fields§
§merges_seen: usizeMerge commits the log produced.
merges_scanned: usizeMerge commits actually compared.
skipped_octopus: usizeMerges with three or more parents, which this comparison does not
model: there is no single proposed side.
skipped_no_base: usizeMerges whose parents share no merge base, or whose objects are missing from a filtered clone.
paths_scanned: usizePaths compared.
skipped_binary: usizePaths where some blob was not valid UTF-8.
skipped_large: usizePaths where some blob exceeded MAX_BLOB_BYTES.
lines_relocated: usizeDistinct lines cancelled as moved between paths within one
merge rather than lost. See scan_merge.
paths_all_relocated: usizePaths whose whole apparent violation was relocation, and which therefore produced no finding.
lines_surviving_elsewhere: usizeDistinct lines reported as reverted that are nonetheless present
somewhere in the merge result. Counted, never cancelled: see
scan_merge on why this is a second number and not a filter.
findings_all_surviving: usizeFindings every one of whose reverted lines survives somewhere in the result, and which carry no injection either. These are the candidates for refactor noise rather than lost work.
findings: Vec<Finding>The violations, in the order found.
Implementations§
Source§impl ScanReport
impl ScanReport
Sourcepub fn merge_violation_rate(&self) -> f64
pub fn merge_violation_rate(&self) -> f64
Merges carrying at least one finding, over merges scanned.
Returns 0.0 for an empty scan rather than a NaN: “nothing was examined” and “nothing was found” must not print the same way.
Trait Implementations§
Source§impl Clone for ScanReport
impl Clone for ScanReport
Source§fn clone(&self) -> ScanReport
fn clone(&self) -> ScanReport
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreSource§impl Debug for ScanReport
impl Debug for ScanReport
Source§impl Default for ScanReport
impl Default for ScanReport
Source§fn default() -> ScanReport
fn default() -> ScanReport
Source§impl PartialEq for ScanReport
impl PartialEq for ScanReport
Source§fn eq(&self, other: &ScanReport) -> bool
fn eq(&self, other: &ScanReport) -> bool
self and other values to be equal, and is used by ==.