diff --git a/Cargo.toml b/Cargo.toml index c80e3e1..6c1928c 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -22,10 +22,11 @@ tokio = { version = "1.39", features = ["full"] } toml = "0.8.0" tracing = { version = "0.1.40", default-features = false } tracing-subscriber = { version = "0.3.17", features = ["env-filter", "json", "fmt"] } +reth-primitives = { git = "https://github.com/paradigmxyz/reth", rev = "a206eb3690e5a51d3c797fed2a6ed722e36863eb", default-features = false } # Citrea dependencies -sov-ledger-rpc = { git = "https://github.com/chainwayxyz/citrea", rev = "82bf52d", default-features = false, features = ["client"] } -sov-rollup-interface = { git = "https://github.com/chainwayxyz/citrea", rev = "82bf52d" } +sov-ledger-rpc = { git = "https://github.com/chainwayxyz/citrea", rev = "879a075590250cd26e721f31c4cedf3b28832cb0", default-features = false, features = ["client"] } +sov-rollup-interface = { git = "https://github.com/chainwayxyz/citrea", rev = "879a075590250cd26e721f31c4cedf3b28832cb0" } [patch.crates-io] bitcoincore-rpc = { version = "0.18.0", git = "https://github.com/chainwayxyz/rust-bitcoincore-rpc.git", rev = "ede8097" } diff --git a/rust-toolchain.toml b/rust-toolchain.toml index 8288054..b80b8f5 100644 --- a/rust-toolchain.toml +++ b/rust-toolchain.toml @@ -1,4 +1,4 @@ [toolchain] -channel = "1.79" +channel = "1.81" components = ["rustfmt", "rust-src", "clippy"] profile = "minimal" diff --git a/src/client.rs b/src/client.rs index 2b70ca0..217e545 100644 --- a/src/client.rs +++ b/src/client.rs @@ -6,7 +6,9 @@ use jsonrpsee::{ http_client::{HttpClient, HttpClientBuilder}, rpc_params, }; +use reth_primitives::U64; use sov_ledger_rpc::client::RpcClient; +use sov_ledger_rpc::HexHash; use sov_rollup_interface::rpc::{ SequencerCommitmentResponse, SoftConfirmationResponse, VerifiedProofResponse, }; @@ -54,7 +56,7 @@ impl Client { pub async fn ledger_get_verified_proofs_by_slot_height( &self, - height: u64, + height: U64, ) -> Result>> { Ok(self .client @@ -64,7 +66,7 @@ impl Client { pub async fn ledger_get_sequencer_commitments_on_slot_by_number( &self, - height: u64, + height: U64, ) -> Result>> { Ok(self .client @@ -74,14 +76,14 @@ impl Client { pub async fn ledger_get_soft_confirmation_by_number( &self, - num: u64, + num: U64, ) -> Result> { Ok(self.client.get_soft_confirmation_by_number(num).await?) } pub async fn ledger_get_sequencer_commitments_on_slot_by_hash( &self, - hash: [u8; 32], + hash: HexHash, ) -> Result>> { self.client .get_sequencer_commitments_on_slot_by_hash(hash) diff --git a/src/full_node.rs b/src/full_node.rs index 1934216..4fe7ba9 100644 --- a/src/full_node.rs +++ b/src/full_node.rs @@ -1,4 +1,5 @@ use anyhow::bail; +use reth_primitives::U64; use sov_rollup_interface::rpc::{SequencerCommitmentResponse, VerifiedProofResponse}; use tokio::time::{sleep, Duration, Instant}; @@ -23,7 +24,7 @@ impl FullNode { match self .client - .ledger_get_sequencer_commitments_on_slot_by_number(height) + .ledger_get_sequencer_commitments_on_slot_by_number(U64::from(height)) .await { Ok(Some(commitments)) => return Ok(commitments), @@ -48,7 +49,7 @@ impl FullNode { match self .client - .ledger_get_verified_proofs_by_slot_height(height) + .ledger_get_verified_proofs_by_slot_height(U64::from(height)) .await? { Some(proofs) => return Ok(proofs),