From 78214588d6b8b7199015113c9d0d8250d6150014 Mon Sep 17 00:00:00 2001 From: practicalswift Date: Sun, 9 Jul 2017 22:51:47 +0200 Subject: [PATCH] Use for-loop instead of list comprehension To make it clear that we are intentionally using it for its side-effects. --- test/functional/p2p-compactblocks.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/test/functional/p2p-compactblocks.py b/test/functional/p2p-compactblocks.py index c5c264765a3f0..91c0c406ff6c7 100755 --- a/test/functional/p2p-compactblocks.py +++ b/test/functional/p2p-compactblocks.py @@ -286,7 +286,8 @@ def test_compactblock_construction(self, node, test_node, version, use_witness_a # Store the raw block in our internal format. block = FromHex(CBlock(), node.getblock("%02x" % block_hash, False)) - [tx.calc_sha256() for tx in block.vtx] + for tx in block.vtx: + tx.calc_sha256() block.rehash() # Wait until the block was announced (via compact blocks)