mirror of
https://github.com/aljazceru/lightning.git
synced 2025-12-23 09:04:22 +01:00
reckless: use modern listconfigs.
Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
This commit is contained in:
@@ -696,9 +696,9 @@ def load_config(reckless_dir: Union[str, None] = None,
|
|||||||
net_conf = None
|
net_conf = None
|
||||||
# Does the lightning-cli already reference an explicit config?
|
# Does the lightning-cli already reference an explicit config?
|
||||||
try:
|
try:
|
||||||
active_config = lightning_cli('listconfigs', timeout=3)
|
active_config = lightning_cli('listconfigs', timeout=3)['configs']
|
||||||
if 'conf' in active_config:
|
if 'conf' in active_config:
|
||||||
net_conf = LightningBitcoinConfig(path=active_config['conf'])
|
net_conf = LightningBitcoinConfig(path=active_config['conf']['value_str'])
|
||||||
except RPCError:
|
except RPCError:
|
||||||
pass
|
pass
|
||||||
if reckless_dir is None:
|
if reckless_dir is None:
|
||||||
|
|||||||
Reference in New Issue
Block a user