Skip to content

Commit

Permalink
Merge b117eb4 into merged_master (Elements PR ElementsProject#747)
Browse files Browse the repository at this point in the history
  • Loading branch information
apoelstra committed Nov 5, 2020
2 parents 7fd560b + b117eb4 commit 38598f1
Showing 1 changed file with 5 additions and 2 deletions.
7 changes: 5 additions & 2 deletions test/functional/feature_blocksign.py
Original file line number Diff line number Diff line change
Expand Up @@ -114,16 +114,19 @@ def mine_block(self, make_transactions):
# miner makes a block
block = miner.getnewblockhex()

# other signing nodes get fed compact blocks
# All nodes get compact blocks, first node may get complete
# block in 0.5 RTT even with transactions thanks to p2p connection
# with non-signing node being miner
for i in range(self.num_keys):
if i == mineridx:
continue
sketch = miner.getcompactsketch(block)
compact_response = self.nodes[i].consumecompactsketch(sketch)
if make_transactions:
if "block_tx_req" in compact_response:
block_txn = self.nodes[i].consumegetblocktxn(block, compact_response["block_tx_req"])
final_block = self.nodes[i].finalizecompactblock(sketch, block_txn, compact_response["found_transactions"])
else:
assert (mineridx == 4 and i == 0) or not make_transactions
# If there's only coinbase, it should succeed immediately
final_block = compact_response["blockhex"]
# Block should be complete, sans signatures
Expand Down

0 comments on commit 38598f1

Please sign in to comment.