Skip to content

Commit

Permalink
Logs lt hash checksums if the feature is off but the cli arg is on (s…
Browse files Browse the repository at this point in the history
  • Loading branch information
brooksprumo authored Nov 13, 2024
1 parent 7585e9b commit 5984d19
Showing 1 changed file with 13 additions and 0 deletions.
13 changes: 13 additions & 0 deletions runtime/src/bank/accounts_lt_hash.rs
Original file line number Diff line number Diff line change
Expand Up @@ -42,6 +42,19 @@ impl Bank {
let delta_lt_hash = self.calculate_delta_lt_hash();
let mut accounts_lt_hash = self.accounts_lt_hash.lock().unwrap();
accounts_lt_hash.0.mix_in(&delta_lt_hash);

// If the feature gate is not yet active, log the lt hash checksums for debug/testing
if !self
.feature_set
.is_active(&feature_set::accounts_lt_hash::id())
{
log::info!(
"updated accounts lattice hash for slot {}, delta_lt_hash checksum: {}, accounts_lt_hash checksum: {}",
self.slot(),
delta_lt_hash.checksum(),
accounts_lt_hash.0.checksum(),
);
}
}

/// Calculates the lt hash *of only this slot*
Expand Down

0 comments on commit 5984d19

Please sign in to comment.