From c67e41d185ec38e07633b0e742faae7eb88ac52a Mon Sep 17 00:00:00 2001 From: Sergi Delgado Segura Date: Fri, 30 Aug 2019 12:58:05 +0200 Subject: [PATCH] Includes getbestblockhash so it can simulate db loads --- test/simulator/bitcoind_sim.py | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/test/simulator/bitcoind_sim.py b/test/simulator/bitcoind_sim.py index 358968a..47248a1 100644 --- a/test/simulator/bitcoind_sim.py +++ b/test/simulator/bitcoind_sim.py @@ -55,6 +55,8 @@ def process_request(): getblockhash: a block hash is only queried by pisad on bootstrapping to check the network bitcoind is running on. + getbestblockhash: returns the hash of the block in the tip of the chain + help: help is only used as a sample command to test if bitcoind is running when bootstrapping pisad. It will return a 200/OK with no data. """ @@ -153,6 +155,9 @@ def process_request(): response["error"] = no_param_err response["error"]["message"] = response["error"]["message"].format("integer") + elif method == "getbestblockhash": + response["result"] = blockchain[-1] + elif method == "help": pass