Skip to content

Commit d8542d1

Browse files
committed
fix(cardano-chain-follower): fix type
1 parent 489a289 commit d8542d1

File tree

3 files changed

+5
-4
lines changed

3 files changed

+5
-4
lines changed

rust/cardano-chain-follower/src/chain_sync.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -444,7 +444,7 @@ async fn live_sync_backfill_and_purge(
444444
stats::new_mithril_update(
445445
cfg.chain,
446446
update.tip.slot_or_default(),
447-
live_chain_length(cfg.chain),
447+
live_chain_length(cfg.chain) as u64,
448448
live_chain_head.slot_or_default(),
449449
);
450450

rust/cardano-chain-follower/src/chain_sync_live_chains.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ use std::{
66
time::Duration,
77
};
88

9-
use cardano_blockchain_types::{Fork, MultiEraBlock, Network, Point};
9+
use cardano_blockchain_types::{Fork, MultiEraBlock, Network, Point, Slot};
1010
use crossbeam_skiplist::SkipMap;
1111
use rayon::prelude::*;
1212
use strum::IntoEnumIterator;
@@ -340,7 +340,7 @@ impl ProtectedLiveChainBlockList {
340340
}
341341

342342
// Now find points based on an every increasing Slot age.
343-
let mut slot_age: u64 = 40;
343+
let mut slot_age: Slot = 40.into();
344344
let reference_slot = entry.value().point().slot_or_default();
345345
let mut previous_point = entry.value().point();
346346

rust/cardano-chain-follower/src/metadata/mod.rs

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,14 +2,15 @@
22
33
use std::{fmt::Debug, sync::Arc};
44

5+
use cardano_blockchain_types::Network;
56
use cip36::Cip36;
67
use cip509::Cip509;
78
use dashmap::DashMap;
89
use pallas::ledger::traverse::{MultiEraBlock, MultiEraTx};
910
use raw_aux_data::RawAuxData;
1011
use tracing::error;
1112

12-
use crate::{utils::usize_from_saturating, Network};
13+
use crate::utils::usize_from_saturating;
1314

1415
pub mod cip36;
1516
pub mod cip509;

0 commit comments

Comments
 (0)