aboutsummaryrefslogtreecommitdiff
path: root/utils
diff options
context:
space:
mode:
authorluigi1111 <luigi1111w@gmail.com>2021-11-26 23:04:57 -0600
committerluigi1111 <luigi1111w@gmail.com>2021-11-26 23:04:57 -0600
commita96fd84502a510fa2600cf0055be7280b96c03a1 (patch)
tree186454925c77e3755e48601e4a97a9253334a923 /utils
parentMerge pull request #8072 (diff)
parentAdd python method (diff)
downloadmonero-a96fd84502a510fa2600cf0055be7280b96c03a1.tar.xz
Merge pull request #8075
6f80a46 Add python method (Howard Chu) c09054b Add calcpow RPC (Howard Chu)
Diffstat (limited to 'utils')
-rw-r--r--utils/python-rpc/framework/daemon.py14
1 files changed, 14 insertions, 0 deletions
diff --git a/utils/python-rpc/framework/daemon.py b/utils/python-rpc/framework/daemon.py
index 3bfe01826..93e91e8c8 100644
--- a/utils/python-rpc/framework/daemon.py
+++ b/utils/python-rpc/framework/daemon.py
@@ -61,6 +61,20 @@ class Daemon(object):
}
return self.rpc.send_json_rpc_request(get_miner_data)
+ def calc_pow(self, major_version, height, block_blob, seed_hash = ''):
+ calc_pow = {
+ 'method': 'calc_pow',
+ 'params': {
+ 'major_version': major_version,
+ 'height': height,
+ 'block_blob' : block_blob,
+ 'seed_hash' : seed_hash,
+ },
+ 'jsonrpc': '2.0',
+ 'id': '0'
+ }
+ return self.rpc.send_json_rpc_request(calc_pow)
+
def send_raw_transaction(self, tx_as_hex, do_not_relay = False, do_sanity_checks = True, client = ""):
send_raw_transaction = {
'client': client,