From 6474a2399aab94b8eed25483f309e89ddc4ec551 Mon Sep 17 00:00:00 2001 From: nolash Date: Mon, 15 Nov 2021 14:29:20 +0100 Subject: [PATCH] Enable call when wallet set for encode cli command --- chainlib/eth/runnable/encode.py | 4 +++- requirements.txt | 2 +- setup.cfg | 2 +- 3 files changed, 5 insertions(+), 3 deletions(-) diff --git a/chainlib/eth/runnable/encode.py b/chainlib/eth/runnable/encode.py index a4f4dbd..f69bea1 100644 --- a/chainlib/eth/runnable/encode.py +++ b/chainlib/eth/runnable/encode.py @@ -55,12 +55,14 @@ config_dir = os.path.join(script_dir, '..', 'data', 'config') arg_flags = chainlib.eth.cli.argflag_std_write | chainlib.eth.cli.Flag.EXEC argparser = chainlib.eth.cli.ArgumentParser(arg_flags) +argparser.add_argument('--notx', type=str, help='Network send is not a transaction') argparser.add_argument('--signature', type=str, help='Method signature to encode') argparser.add_argument('contract_args', type=str, nargs='*', help='arguments to encode') args = argparser.parse_args() extra_args = { 'signature': None, 'contract_args': None, + 'notx': None, } config = chainlib.eth.cli.Config.from_args(args, arg_flags, extra_args=extra_args, default_config_dir=config_dir) @@ -109,7 +111,7 @@ def main(): exec_address = add_0x(to_checksum_address(config.get('_EXEC_ADDRESS'))) - if signer == None: + if signer == None or config.true('_NOTX'): c = TxFactory(chain_spec) j = JSONRPCRequest(id_generator=rpc.id_generator) o = j.template() diff --git a/requirements.txt b/requirements.txt index ad3127e..8c3da97 100644 --- a/requirements.txt +++ b/requirements.txt @@ -3,5 +3,5 @@ pysha3==1.0.2 hexathon~=0.1.0 websocket-client==0.57.0 potaahto~=0.1.0 -chainlib==0.0.11 +chainlib~=0.0.12 confini~=0.5.1 diff --git a/setup.cfg b/setup.cfg index d6680e1..32be722 100644 --- a/setup.cfg +++ b/setup.cfg @@ -1,6 +1,6 @@ [metadata] name = chainlib-eth -version = 0.0.11 +version = 0.0.13a1 description = Ethereum implementation of the chainlib interface author = Louis Holbrook author_email = dev@holbrook.no