Skip to content

Commit

Permalink
chore: just put the error plainly on the return (#302)
Browse files Browse the repository at this point in the history
* chore: just put the error plainly on the return

* lint

* chore: move log back into error
  • Loading branch information
renancloudwalk authored Mar 4, 2024
1 parent 596533a commit 836d08a
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/eth/evm/revm.rs
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@ use std::sync::Arc;
use std::time::Instant;

use anyhow::anyhow;
use anyhow::Context;
use itertools::Itertools;
use revm::primitives::AccountInfo;
use revm::primitives::Address as RevmAddress;
Expand Down Expand Up @@ -108,7 +109,7 @@ impl Evm for Revm {
Ok(result) => Ok(parse_revm_execution(result, session.input, session.storage_changes)),
Err(e) => {
tracing::warn!(reason = ?e, "evm execution error");
Err(anyhow!("Error executing EVM transaction. Check logs for more information."))
Err(e).context("Error executing EVM transaction.")
}
};

Expand Down

0 comments on commit 836d08a

Please sign in to comment.