MCPcopy Create free account
hub / github.com/ElementsProject/lightning / bcli

Function bcli

tests/plugins/badestimate.py:16–25  ·  view source on GitHub ↗
(plugin, cmd)

Source from the content-addressed store, hash-verified

14
15
16def bcli(plugin, cmd):
17 ret = subprocess.run([cli,
18 '-datadir={}'.format(plugin.get_option("bitcoin-datadir")),
19 '-rpcuser={}'.format(plugin.get_option("bitcoin-rpcuser")),
20 '-rpcpassword={}'.format(plugin.get_option("bitcoin-rpcpassword")),
21 '-rpcport={}'.format(plugin.get_option("bitcoin-rpcport"))]
22 + cmd, stdout=subprocess.PIPE)
23 if ret.returncode != 0:
24 return None
25 return ret.stdout.decode('utf-8')
26
27
28@plugin.method("estimatefees")

Callers 4

getrawblockbyheightFunction · 0.85
getchaininfoFunction · 0.85
sendrawtransactionFunction · 0.85
getutxoutFunction · 0.85

Calls 3

get_optionMethod · 0.80
runMethod · 0.45
decodeMethod · 0.45

Tested by

no test coverage detected