Page Menu
Home
Phabricator
Search
Configure Global Search
Log In
Files
F13115626
D8846.diff
No One
Temporary
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Award Token
Flag For Later
Size
751 B
Subscribers
None
D8846.diff
View Options
diff --git a/test/functional/feature_block.py b/test/functional/feature_block.py
--- a/test/functional/feature_block.py
+++ b/test/functional/feature_block.py
@@ -497,7 +497,7 @@
self.move_tip(44)
b47 = self.next_block(47, solve=False)
target = uint256_from_compact(b47.nBits)
- while b47.sha256 < target:
+ while b47.sha256 <= target:
b47.nNonce += 1
b47.rehash()
self.send_blocks(
@@ -1227,6 +1227,8 @@
block.hashMerkleRoot = block.calc_merkle_root()
if solve:
block.solve()
+ else:
+ block.rehash()
self.tip = block
self.block_heights[block.sha256] = height
assert number not in self.blocks
File Metadata
Details
Attached
Mime Type
text/plain
Expires
Sat, Mar 1, 11:34 (5 h, 55 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
5187638
Default Alt Text
D8846.diff (751 B)
Attached To
D8846: Fix mining to an invalid target + ensure that a new block has the correct hash internally in Python tests
Event Timeline
Log In to Comment