rpc: Include assumeutxo as a failure reason of rescanblockchain

This commit is contained in:
Fabian Jahr committed 2025-01-05 17:28:34 +01:00
1 parent 595edee169
commit 9d2d9f7ce2
2 files changed
+13 -2

No files matched your search

+4
View File
@@ -176,6 +176,10 @@ class AssumeutxoTest(BitcoinTestFramework):
assert_equal(result[0]['error']['code'], -1)
assert_equal(result[0]['error']['message'], expected_error_message)
self.log.info("Test that rescanning blocks from before the snapshot fails when blocks are not available from the background sync yet")
w1 = n1.get_wallet_rpc(wallet_name)
assert_raises_rpc_error(-1, "Failed to rescan unavailable blocks likely due to an in-progress assumeutxo background sync. Check logs or getchainstates RPC for assumeutxo background sync progress and try again later.", w1.rescanblockchain, 100)
PAUSE_HEIGHT = FINAL_HEIGHT - 40
self.log.info("Restarting node to stop at height %d", PAUSE_HEIGHT)