You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
info!("Miner node: checking UTXOs at address: {}",&btc_addr);
192
-
let utxos = burnchain.get_utxos(epoch_id,&op_signer.get_public_key(),1,None,0);
193
-
if utxos.is_none(){
194
-
warn!("UTXOs not found for {}. If this is unexpected, please ensure that your bitcoind instance is indexing transactions for the address {} (importaddress)", btc_addr, btc_addr);
195
-
}else{
196
-
info!("UTXOs found - will run as a Miner node");
195
+
// retry UTXO check a few times, in case bitcoind is still starting up
196
+
for _ in0..Self::UTXO_RETRY_COUNT{
197
+
for(epoch_id, btc_addr)in&btc_addrs {
198
+
info!("Miner node: checking UTXOs at address: {btc_addr}");
warn!("UTXOs not found for {btc_addr}. If this is unexpected, please ensure that your bitcoind instance is indexing transactions for the address {btc_addr} (importaddress)");
203
+
}else{
204
+
info!("UTXOs found - will run as a Miner node");
205
+
returntrue;
206
+
}
207
+
}
208
+
ifself.config.get_node_config(false).mock_mining{
209
+
info!("No UTXOs found, but configured to mock mine");
info!("Miner node: checking UTXOs at address: {}",&btc_addr);
395
-
let utxos = burnchain.get_utxos(epoch_id,&op_signer.get_public_key(),1,None,0);
396
-
if utxos.is_none(){
397
-
warn!("UTXOs not found for {}. If this is unexpected, please ensure that your bitcoind instance is indexing transactions for the address {} (importaddress)", btc_addr, btc_addr);
398
-
}else{
399
-
info!("UTXOs found - will run as a Miner node");
398
+
// retry UTXO check a few times, in case bitcoind is still starting up
399
+
for _ in0..Self::UTXO_RETRY_COUNT{
400
+
for(epoch_id, btc_addr)in&btc_addrs {
401
+
info!("Miner node: checking UTXOs at address: {btc_addr}");
warn!("UTXOs not found for {btc_addr}. If this is unexpected, please ensure that your bitcoind instance is indexing transactions for the address {btc_addr} (importaddress)");
406
+
}else{
407
+
info!("UTXOs found - will run as a Miner node");
408
+
returntrue;
409
+
}
410
+
}
411
+
ifself.config.get_node_config(false).mock_mining{
412
+
info!("No UTXOs found, but configured to mock mine");
0 commit comments