From 2bbed7727fee4a8229ee9aec0f403048aa59f038 Mon Sep 17 00:00:00 2001 From: sakridge Date: Mon, 15 Apr 2019 16:30:00 -0700 Subject: [PATCH] Wait a bit for the funding transactions to go through (#3788) --- bench-tps/src/bench.rs | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/bench-tps/src/bench.rs b/bench-tps/src/bench.rs index 2a11d8bb6..83a6b746f 100644 --- a/bench-tps/src/bench.rs +++ b/bench-tps/src/bench.rs @@ -593,7 +593,13 @@ fn fund_keys(client: &ThinClient, source: &Keypair, dests: &[Keypair], lamports: // retry anything that seems to have dropped through cracks // again since these txs are all or nothing, they're fine to // retry - to_fund_txs.retain(|(_, tx)| !verify_funding_transfer(client, &tx, amount)); + for _ in 0..10 { + to_fund_txs.retain(|(_, tx)| !verify_funding_transfer(client, &tx, amount)); + if to_fund_txs.is_empty() { + break; + } + sleep(Duration::from_millis(100)); + } tries += 1; }