Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions .github/workflows/run-tests-on-push-to-main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,7 @@ jobs:
--package acropolis_module_block_unpacker \
--package acropolis_module_consensus \
--package acropolis_module_drdd_state \
--package acropolis_module_mithril_snapshot_fetcher \
--package acropolis_module_snapshot_bootstrapper \
--package acropolis_module_spdd_state \
--package acropolis_module_utxo_state
Expand Down
12 changes: 5 additions & 7 deletions modules/mithril_snapshot_fetcher/src/mithril_snapshot_fetcher.rs
Original file line number Diff line number Diff line change
Expand Up @@ -208,7 +208,7 @@ impl MithrilSnapshotFetcher {
// Download the snapshot
fs::create_dir_all(&directory)?;
let dir = Path::new(&directory);
client.cardano_database().download_unpack(&snapshot, &dir).await?;
client.cardano_database().download_unpack(&snapshot, dir).await?;

// Register download
if let Err(e) = client.cardano_database().add_statistics(&snapshot).await {
Expand Down Expand Up @@ -281,9 +281,8 @@ impl MithrilSnapshotFetcher {
}

// Skip EBBs
match block {
MultiEraBlock::EpochBoundary(_) => return Ok::<(), anyhow::Error>(()),
_ => {}
if let MultiEraBlock::EpochBoundary(_) = block {
return Ok(());
}

// Error and ignore any out of sequence
Expand Down Expand Up @@ -424,9 +423,8 @@ impl MithrilSnapshotFetcher {
delay = (delay * 2).min(60);
}

match Self::process_snapshot(context, config, genesis).await {
Err(e) => error!("Failed to process Mithril snapshot: {e}"),
_ => {}
if let Err(e) = Self::process_snapshot(context, config, genesis).await {
error!("Failed to process Mithril snapshot: {e}");
}
});

Expand Down
2 changes: 1 addition & 1 deletion modules/mithril_snapshot_fetcher/src/pause.rs
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@ impl PauseType {
if block_info.new_epoch {
return block_info.epoch == *target_epoch;
}
return false;
false
}
PauseType::Block(target_block) => block_info.number == *target_block,
PauseType::NoPause => false,
Expand Down