commit e225b4e3334735cf5ab9ae0815628c1a8c3e334a
parent 36bd98f3df2bf5b485669827be9e230248256c03
Author: lash <dev@holbrook.no>
Date: Fri, 13 May 2022 07:48:48 +0000
Conceal wait settings behind config check
Diffstat:
2 files changed, 7 insertions(+), 6 deletions(-)
diff --git a/chainlib/cli/arg.py b/chainlib/cli/arg.py
@@ -71,7 +71,7 @@ class ArgFlag(BaseArgFlag):
self.alias('sign', 'key_file', 'send')
self.alias('std_base', 'verbose', 'config', 'raw', 'env', 'target')
self.alias('std_base_read', 'verbose', 'config', 'raw', 'env', 'provider', 'chain_spec', 'seq')
- self.alias('std_read', 'std_base', 'provider', 'chain_spec', 'unsafe', 'seq', 'key_file', 'fee', 'target')
+ self.alias('std_read', 'std_base', 'provider', 'chain_spec', 'unsafe', 'seq', 'sign', 'fee', 'target')
self.alias('std_write', 'verbose', 'config', 'raw', 'env', 'provider', 'chain_spec', 'unsafe', 'seq', 'key_file', 'sign', 'target', 'wait', 'wait_all', 'send', 'rpc_auth', 'nonce', 'fee')
self.alias('std_target', 'no_target', 'exec', 'wallet')
diff --git a/chainlib/cli/config.py b/chainlib/cli/config.py
@@ -107,11 +107,12 @@ def process_config(config, arg, args, flags):
if arg.match('nonce', flags):
config.add(getattr(args, 'nonce'), '_NONCE')
- if args.ww:
- config.add(True, '_WAIT_ALL')
- config.add(True, '_WAIT')
- elif args.w:
- config.add(True, '_WAIT')
+ if arg.match('wait', flags):
+ if args.ww:
+ config.add(True, '_WAIT_ALL')
+ config.add(True, '_WAIT')
+ elif args.w:
+ config.add(True, '_WAIT')
if arg.match('seq', flags):
config.add(getattr(args, 'seq'), '_SEQ')