This commit is contained in:
pgherveou
2025-10-08 06:28:57 +00:00
parent 765569a8b6
commit 1f84ce6f61
34 changed files with 1093 additions and 503 deletions
+4 -1
View File
@@ -27,7 +27,10 @@ pub fn read(path: impl AsRef<Path>) -> Result<Vec<u8>> {
pub fn read_to_string(path: impl AsRef<Path>) -> Result<String> {
let content = read(path)?;
String::from_utf8(content).map_err(|_| {
Error::new(std::io::ErrorKind::InvalidData, "The contents of the file are not valid UTF8")
Error::new(
std::io::ErrorKind::InvalidData,
"The contents of the file are not valid UTF8",
)
})
}
+4 -1
View File
@@ -12,7 +12,10 @@ pub fn clear_directory(path: impl AsRef<Path>) -> Result<()> {
.with_context(|| format!("Failed to read directory: {}", path.as_ref().display()))?
{
let entry = entry.with_context(|| {
format!("Failed to read an entry in directory: {}", path.as_ref().display())
format!(
"Failed to read an entry in directory: {}",
path.as_ref().display()
)
})?;
let entry_path = entry.path();
+4 -1
View File
@@ -37,7 +37,10 @@ where
));
}
match future().await.context("Polled future returned an error during polling loop")? {
match future()
.await
.context("Polled future returned an error during polling loop")?
{
ControlFlow::Continue(()) => {
let next_wait_duration = match polling_wait_behavior {
PollingWaitBehavior::Constant(duration) => duration,
+3 -1
View File
@@ -76,7 +76,9 @@ impl FromStr for ModePipeline {
// Don't go via Yul IR
"E" => Ok(ModePipeline::ViaEVMAssembly),
// Anything else that we see isn't a mode at all
_ => Err(anyhow::anyhow!("Unsupported pipeline '{s}': expected 'Y' or 'E'")),
_ => Err(anyhow::anyhow!(
"Unsupported pipeline '{s}': expected 'Y' or 'E'"
)),
}
}
}