From 95ccc40ac65d43886d59dbf13de25d2c265c0f73 Mon Sep 17 00:00:00 2001 From: Arya Date: Mon, 7 Oct 2024 14:31:53 -0400 Subject: [PATCH] adds a few log messages to the acceptance test, reduces frequency of logs for progress updates --- zebrad/tests/acceptance.rs | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/zebrad/tests/acceptance.rs b/zebrad/tests/acceptance.rs index 43fecf65c03..02ec0802407 100644 --- a/zebrad/tests/acceptance.rs +++ b/zebrad/tests/acceptance.rs @@ -3557,6 +3557,8 @@ async fn has_spending_transaction_ids() -> Result<()> { let test_name = "has_spending_transaction_ids_test"; let network = Mainnet; + tracing::info!("loading blocks for non-finalized state"); + let non_finalized_blocks = future_blocks(&network, test_type, test_name, 100).await?; let zebrad_state_path = test_type @@ -3567,6 +3569,8 @@ async fn has_spending_transaction_ids() -> Result<()> { common::cached_state::start_state_service_with_cache_dir(&Mainnet, zebrad_state_path) .await?; + tracing::info!("committing blocks to non-finalized state"); + for block in non_finalized_blocks { let expected_hash = block.hash(); let block = SemanticallyVerifiedBlock::with_hash(Arc::new(block), expected_hash); @@ -3591,6 +3595,8 @@ async fn has_spending_transaction_ids() -> Result<()> { .best_tip_hash() .expect("cached state must not be empty"); + tracing::info!("checking indexes of spending transaction ids"); + // Read the last 500 blocks - should be greater than the MAX_BLOCK_REORG_HEIGHT so that // both the finalized and non-finalized state are checked. let num_blocks_to_check = 500; @@ -3641,7 +3647,7 @@ async fn has_spending_transaction_ids() -> Result<()> { ); } - if i % 10 == 0 { + if i % 25 == 0 { tracing::info!( height = ?block.coinbase_height(), "has all spending tx ids at and above block"