From 89d5ac75588a9558a1827df6a46c02088e4a8b83 Mon Sep 17 00:00:00 2001 From: UdjinM6 Date: Sat, 3 Feb 2024 19:12:39 +0300 Subject: [PATCH 1/2] fix feature_llmq_simplepose.py --- test/functional/feature_llmq_simplepose.py | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) diff --git a/test/functional/feature_llmq_simplepose.py b/test/functional/feature_llmq_simplepose.py index a28a89e566f7..135d7d97591f 100755 --- a/test/functional/feature_llmq_simplepose.py +++ b/test/functional/feature_llmq_simplepose.py @@ -189,21 +189,22 @@ def repair_masternodes(self, restart): addr = self.nodes[0].getnewaddress() self.nodes[0].sendtoaddress(addr, 0.1) self.nodes[0].protx('update_service', mn.proTxHash, '127.0.0.1:%d' % p2p_port(mn.node.index), mn.keyOperator, "", addr) - # Make sure this tx "safe" to mine even when InstantSend and ChainLocks are no longer functional - self.bump_mocktime(60 * 10 + 1) - self.nodes[0].generate(1) - assert not self.check_banned(mn) - if restart: self.stop_node(mn.node.index) self.start_masternode(mn) else: mn.node.setnetworkactive(True) self.connect_nodes(mn.node.index, 0) + + # Make sure protxes are "safe" to mine even when InstantSend and ChainLocks are no longer functional + self.bump_mocktime(60 * 10 + 1) + self.nodes[0].generate(1) + self.wait_until(lambda: all([x.getconnectioncount() > 0 for x in self.nodes])) self.sync_all() # Isolate and re-connect all MNs (otherwise there might be open connections with no MNAUTH for MNs which were banned before) for mn in self.mninfo: + assert not self.check_banned(mn) mn.node.setnetworkactive(False) self.wait_until(lambda: mn.node.getconnectioncount() == 0) mn.node.setnetworkactive(True) From 623c30d05bad37152531328f57e67a788d492f9b Mon Sep 17 00:00:00 2001 From: UdjinM6 Date: Sat, 3 Feb 2024 23:30:02 +0300 Subject: [PATCH 2/2] fix: sync before bumping mocktime --- test/functional/feature_llmq_simplepose.py | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/test/functional/feature_llmq_simplepose.py b/test/functional/feature_llmq_simplepose.py index 135d7d97591f..e5b9f2882a91 100755 --- a/test/functional/feature_llmq_simplepose.py +++ b/test/functional/feature_llmq_simplepose.py @@ -196,10 +196,12 @@ def repair_masternodes(self, restart): mn.node.setnetworkactive(True) self.connect_nodes(mn.node.index, 0) + # syncing blocks only since node 0 has txes waiting to be mined + self.sync_blocks() + # Make sure protxes are "safe" to mine even when InstantSend and ChainLocks are no longer functional self.bump_mocktime(60 * 10 + 1) self.nodes[0].generate(1) - self.wait_until(lambda: all([x.getconnectioncount() > 0 for x in self.nodes])) self.sync_all() # Isolate and re-connect all MNs (otherwise there might be open connections with no MNAUTH for MNs which were banned before)