Inline the verdict header, and take the formatter's pass
clippy::print_literal on the results table header, and rustfmt's first look at code whose author could not run cargo. The four constructs the author flagged as risky -- scoped-thread lanes, a seventeen-argument params!, is_some_and over a closure, a refutable let-else -- all compiled untouched. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
This commit is contained in:
@@ -331,7 +331,10 @@ fn collect(
|
|||||||
v.insert("catalog_filtered_ms".to_string(), open.filtered_ms);
|
v.insert("catalog_filtered_ms".to_string(), open.filtered_ms);
|
||||||
let ips = thumbs.images_per_second;
|
let ips = thumbs.images_per_second;
|
||||||
v.insert("thumbnail_throughput_ips".to_string(), ips);
|
v.insert("thumbnail_throughput_ips".to_string(), ips);
|
||||||
v.insert("thumbnail_per_image_p99_ms".to_string(), thumbs.per_image.p99);
|
v.insert(
|
||||||
|
"thumbnail_per_image_p99_ms".to_string(),
|
||||||
|
thumbs.per_image.p99,
|
||||||
|
);
|
||||||
for row in exports {
|
for row in exports {
|
||||||
v.insert(row.key.to_string(), row.times.p99);
|
v.insert(row.key.to_string(), row.times.p99);
|
||||||
}
|
}
|
||||||
@@ -472,8 +475,8 @@ fn print_verdict(
|
|||||||
}
|
}
|
||||||
println!();
|
println!();
|
||||||
println!(
|
println!(
|
||||||
" {:<30} {:>12} {:>13} {:>12} {:>8} {}",
|
" {:<30} {:>12} {:>13} {:>12} {:>8} verdict",
|
||||||
"metric", "measured", "budget", "baseline", "drift", "verdict"
|
"metric", "measured", "budget", "baseline", "drift"
|
||||||
);
|
);
|
||||||
|
|
||||||
let mut failures = Vec::new();
|
let mut failures = Vec::new();
|
||||||
@@ -521,9 +524,7 @@ fn print_verdict(
|
|||||||
"ok"
|
"ok"
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
println!(
|
println!(" {key:<30} {measured:>12.2} {budget:>13} {recorded:>12} {drift:>8} {verdict}");
|
||||||
" {key:<30} {measured:>12.2} {budget:>13} {recorded:>12} {drift:>8} {verdict}"
|
|
||||||
);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
// A metric in the file that nothing measured is a harness that has drifted
|
// A metric in the file that nothing measured is a harness that has drifted
|
||||||
|
|||||||
@@ -173,7 +173,10 @@ pub fn in_a_fresh_process(catalog_path: &Path) -> Result<Rss> {
|
|||||||
.and_then(|v| v.parse::<u64>().ok())
|
.and_then(|v| v.parse::<u64>().ok())
|
||||||
};
|
};
|
||||||
let (Some(now_kb), Some(peak_kb)) = (field("rss_kb="), field("peak_kb=")) else {
|
let (Some(now_kb), Some(peak_kb)) = (field("rss_kb="), field("peak_kb=")) else {
|
||||||
anyhow::bail!("the memory probe printed something unreadable: {}", text.trim());
|
anyhow::bail!(
|
||||||
|
"the memory probe printed something unreadable: {}",
|
||||||
|
text.trim()
|
||||||
|
);
|
||||||
};
|
};
|
||||||
Ok(Rss { now_kb, peak_kb })
|
Ok(Rss { now_kb, peak_kb })
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user