fix(sync): done flag for index history stages (#1935)

This commit is contained in:
Roman Krasiuk
2023-03-23 19:15:16 +02:00
committed by GitHub
parent a45ef688b4
commit c29d733f5c
2 changed files with 2 additions and 2 deletions

View File

@@ -53,7 +53,7 @@ impl<DB: Database> Stage<DB> for IndexAccountHistoryStage {
tx.insert_account_history_index(indices)?;
info!(target: "sync::stages::index_account_history", "Stage finished");
Ok(ExecOutput { stage_progress: to_block, done: true })
Ok(ExecOutput { stage_progress: to_block, done: to_block == previous_stage_progress })
}
/// Unwind the stage.

View File

@@ -54,7 +54,7 @@ impl<DB: Database> Stage<DB> for IndexStorageHistoryStage {
tx.insert_storage_history_index(indices)?;
info!(target: "sync::stages::index_storage_history", "Stage finished");
Ok(ExecOutput { stage_progress: to_block, done: true })
Ok(ExecOutput { stage_progress: to_block, done: to_block == previous_stage_progress })
}
/// Unwind the stage.