From ed3f80bbb8a68b8ef0c39991dee447540771d930 Mon Sep 17 00:00:00 2001 From: Noah Citron Date: Tue, 20 Aug 2024 16:57:13 -0400 Subject: [PATCH] pass ci --- examples/call.rs | 16 +++++++++++----- execution/src/rpc/http_rpc.rs | 2 +- 2 files changed, 12 insertions(+), 6 deletions(-) diff --git a/examples/call.rs b/examples/call.rs index 74612109..9e0023b7 100644 --- a/examples/call.rs +++ b/examples/call.rs @@ -3,6 +3,7 @@ use std::path::PathBuf; use alloy::primitives::{Address, Bytes}; +use alloy::rpc::types::TransactionRequest; use dotenv::dotenv; use tracing::info; use tracing_subscriber::filter::{EnvFilter, LevelFilter}; @@ -11,7 +12,7 @@ use tracing_subscriber::FmtSubscriber; use helios::{ client::{Client, ClientBuilder, FileDB}, config::networks::Network, - types::{BlockTag, CallOpts}, + types::BlockTag, }; #[tokio::main] @@ -53,16 +54,21 @@ async fn main() -> eyre::Result<()> { client.wait_synced().await; // Call on helios client - let call_opts = CallOpts { + let tx = TransactionRequest { from: None, - to: Some("0x6B175474E89094C44Da98b954EedeAC495271d0F".parse::
()?), + to: Some( + "0x6B175474E89094C44Da98b954EedeAC495271d0F" + .parse::
()? + .into(), + ), gas: None, gas_price: None, value: None, - data: Some("0x18160ddd".parse::()?), + input: "0x18160ddd".parse::()?.into(), + ..Default::default() }; - let result = client.call(&call_opts, BlockTag::Latest).await?; + let result = client.call(&tx, BlockTag::Latest).await?; info!("[HELIOS] DAI total supply: {:?}", result); Ok(()) diff --git a/execution/src/rpc/http_rpc.rs b/execution/src/rpc/http_rpc.rs index 16ed8f9b..9804fc78 100644 --- a/execution/src/rpc/http_rpc.rs +++ b/execution/src/rpc/http_rpc.rs @@ -73,7 +73,7 @@ impl ExecutionRpc for HttpRpc { let list = self .provider - .create_access_list(&tx) + .create_access_list(tx) .block_id(block) .await .map_err(|e| RpcError::new("create_access_list", e))?;