looping twice over block, let's see what the logs say

This commit is contained in:
Greg Coppola
2022-07-07 16:55:33 -05:00
parent 33372af5c0
commit c566656830
3 changed files with 51 additions and 47 deletions

View File

@@ -1507,7 +1507,7 @@ impl<'a> ClarityDatabase<'a> {
pub fn get_account_stx_balance(&mut self, principal: &PrincipalData) -> STXBalance {
let key = ClarityDatabase::make_key_for_account_balance(principal);
debug!("Fetching account balance"; "principal" => %principal.to_string());
// debug!("Fetching account balance"; "principal" => %principal.to_string());
let result = self.get(&key);
match result {
None => STXBalance::zero(),

View File

@@ -1053,7 +1053,7 @@ impl MemPoolDB {
remember_start_with_estimate = Some(start_with_no_estimate);
let mut last_addr = None;
for address in addresses.into_iter() {
debug!("Update nonce"; "address" => %address);
// debug!("Update nonce"; "address" => %address);
// do not recheck nonces if the sponsor == origin
if last_addr.as_ref() == Some(&address) {
continue;

View File

@@ -767,6 +767,7 @@ simulating a miner.
settings.max_miner_time_ms = max_time;
settings.mempool_settings.min_tx_fee = min_fee;
for i in 0..2 {
let result = StacksBlockBuilder::build_anchored_block(
&chain_state,
&sort_db.index_conn(),
@@ -776,12 +777,14 @@ simulating a miner.
VRFProof::empty(),
Hash160([0; 20]),
&coinbase_tx,
settings,
settings.clone(),
None,
);
let stop = get_epoch_time_ms();
info!("round {} finishes with: {:?}", i, &result);
println!(
"{} mined block @ height = {} off of {} ({}/{}) in {}ms. Min-fee: {}, Max-time: {}",
if result.is_ok() {
@@ -814,6 +817,7 @@ simulating a miner.
&execution_cost
);
}
}
process::exit(0);
}