You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
expected_error(log_msg=f"bad snapshot - coins left over after deserializing 298 coins"ifoff==-1elsef"bad snapshot format or truncated snapshot after deserializing 299 coins")
94
94
95
-
self.log.info(" - snapshot file with wrong outpoint hash")
96
-
withopen(bad_snapshot_path, "wb") asf:
97
-
f.write(valid_snapshot_contents[:(32+8)])
98
-
f.write(b"\xff"*32)
99
-
f.write(valid_snapshot_contents[(32+8+32):])
100
-
expected_error(log_msg="[snapshot] bad snapshot content hash: expected ef45ccdca5898b6c2145e4581d2b88c56564dd389e4bd75a1aaf6961d3edd3c0, got 29926acf3ac81f908cf4f22515713ca541c08bb0f0ef1b2c3443a007134d69b8")
101
-
102
-
self.log.info(" - snapshot file with wrong outpoint index")
103
-
withopen(bad_snapshot_path, "wb") asf:
104
-
f.write(valid_snapshot_contents[:(32+8+32)])
105
-
new_index=1# The correct index is 0
106
-
f.write(new_index.to_bytes(4, "little"))
107
-
f.write(valid_snapshot_contents[(32+8+32+4):])
108
-
expected_error(log_msg="[snapshot] bad snapshot content hash: expected ef45ccdca5898b6c2145e4581d2b88c56564dd389e4bd75a1aaf6961d3edd3c0, got 798266c2e1f9a98fe5ce61f5951cbf47130743f3764cf3cbc254be129142cf9d")
95
+
self.log.info(" - snapshot file with alternated UTXO data")
0 commit comments