Skip to content

Commit

Permalink
chore: adjust log messages to specify 'metadata.size' for clarity in …
Browse files Browse the repository at this point in the history
…mismatch reports. (rooch-network#2451)

This helps to precisely identify discrepancies in various components like utxo_store, address_mapping, and inscription_store during the genesis data verification process.
  • Loading branch information
popcnt1 authored Aug 16, 2024
1 parent d3fed5c commit 3a04190
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions crates/rooch/src/commands/statedb/commands/genesis_verify.rs
Original file line number Diff line number Diff line change
Expand Up @@ -342,15 +342,15 @@ fn verify_utxo(
result = "FAILED";
println!("------------FAILED----------------");
println!(
"[utxo_store] mismatched size: exp: {}, act: {}",
"[utxo_store] mismatched metadata.size: exp: {}, act: {}",
utxo_total, act_utxo_store_state.metadata.size
)
};
if act_address_mapping_state.metadata.size != added_address_set.len() as u64 {
result = "FAILED";
println!("------------FAILED----------------");
println!(
"[address_mapping] mismatched size: exp: {}, act: {}",
"[address_mapping] mismatched metadata.size: exp: {}, act: {}",
added_address_set.len(),
act_address_mapping_state.metadata.size
)
Expand Down Expand Up @@ -508,7 +508,7 @@ fn verify_inscription(
result = "FAILED";
println!("------------FAILED----------------");
println!(
"[inscription_store] mismatched size. metadata: exp: {}, act: {}; cursed: exp: {}, act: {}; blessed: exp: {}, act: {}; next_sequence_number: exp: {}, act: {}",
"[inscription_store] mismatched. metadata.size: exp: {}, act: {}; cursed: exp: {}, act: {}; blessed: exp: {}, act: {}; next_sequence_number: exp: {}, act: {}",
total * 2,
act_inscription_store_state.metadata.size,
cursed_inscription_count,
Expand Down

0 comments on commit 3a04190

Please sign in to comment.