@@ -151,6 +151,10 @@ async def main(length: int, fill_rate: int, profile: bool, block_refs: bool, out
151
151
prev_tx_hash : Optional [bytes32 ] = None
152
152
for bl in blocks :
153
153
if bl .is_transaction_block ():
154
+ reward_coins = bl .get_included_reward_coins ()
155
+ for coin in reward_coins :
156
+ if coin .puzzle_hash in {farmer_puzzlehash , pool_puzzlehash }:
157
+ unspent_coins .append (coin )
154
158
# Update coin store and mempool with new block
155
159
br = BenchBlockRecord (
156
160
header_hash = bl .header_hash ,
@@ -159,16 +163,13 @@ async def main(length: int, fill_rate: int, profile: bool, block_refs: bool, out
159
163
prev_transaction_block_height = prev_tx_height ,
160
164
prev_transaction_block_hash = prev_tx_hash ,
161
165
)
162
- await coin_store .new_block (bl .height , block_timestamp , bl . get_included_reward_coins () , [], [])
166
+ await coin_store .new_block (bl .height , block_timestamp , reward_coins , [], [])
163
167
await mempool_manager .new_peak (br , [])
164
168
prev_tx_height = bl .height
165
169
prev_tx_hash = bl .header_hash
166
170
prev_tx_block = bl # last transaction block
167
171
168
172
block_timestamp = uint64 (block_timestamp + int (time_per_block ))
169
- for coin in bl .get_included_reward_coins ():
170
- if coin .puzzle_hash in {farmer_puzzlehash , pool_puzzlehash }:
171
- unspent_coins .append (coin )
172
173
db .execute (
173
174
"INSERT INTO full_blocks VALUES(?, ?, ?, ?, ?)" ,
174
175
(
0 commit comments