Inside Bitcoin
Opening the selected file…
Inside Bitcoin
Opening the selected file…
The code behind the network, with room to understand it.
Release published 2026-10-28 · Snapshot fetched 2026-11-01. Latest stable release at fetch time; development branches and Git history are excluded. Only the selected code window and visible folders load here.
501assert genesis_blockhash in node.scanblocks(502"start", [{"desc": f"raw({false_positive_spk.hex()})"}], 0, 0)['relevant_blocks']504assert_raises_rpc_error(-1, "Block not available (pruned data)", node.scanblocks,505"start", [{"desc": f"raw({false_positive_spk.hex()})"}], 0, 0, "basic", {"filter_false_positives": True})507def test_pruneheight_undo_presence(self):508node = self.nodes[5]509pruneheight = node.getblockchaininfo()["pruneheight"]510fetch_block = node.getblockhash(pruneheight - 1)512self.connect_nodes(1, 5)513peers = node.getpeerinfo()514node.getblockfrompeer(fetch_block, peers[0]["id"])515self.wait_until(lambda: not try_rpc(-1, "Block not available (pruned data)", node.getblock, fetch_block), timeout=5)517new_pruneheight = node.getblockchaininfo()["pruneheight"]518assert_equal(pruneheight, new_pruneheight)520if __name__ == '__main__':521PruneTest(__file__).main()
Independent explanations by MyBitcoinExplorer. Not affiliated with or endorsed by Bitcoin Core. Guides are educational and do not replace the source or its tests.
Bitcoin Core source © its contributors, distributed under the MIT license. Original notices and bundled third-party licenses are retained in the source tree.