From 5d7c5556d40b826d9b1fd39a0437a8433e877536 Mon Sep 17 00:00:00 2001 From: nolash Date: Sat, 28 Aug 2021 10:24:46 +0200 Subject: [PATCH] Fix gaslimit bug in chainlib eth cli --- chainlib/eth/cli.py | 3 ++- chainlib/eth/gas.py | 2 +- setup.cfg | 2 +- 3 files changed, 4 insertions(+), 3 deletions(-) diff --git a/chainlib/eth/cli.py b/chainlib/eth/cli.py index ac8a725..6172bcd 100644 --- a/chainlib/eth/cli.py +++ b/chainlib/eth/cli.py @@ -99,9 +99,10 @@ class Config(BaseConfig): default_base_config_dir = os.path.join(script_dir, 'data', 'config') default_fee_limit = 21000 - @classmethod def from_args(cls, args, arg_flags=0x0f, env=os.environ, extra_args={}, base_config_dir=None, default_config_dir=None, user_config_dir=None, default_fee_limit=None, logger=None, load_callback=None): + if default_fee_limit == None: + default_fee_limit = cls.default_fee_limit config = BaseConfig.from_args(args, arg_flags=arg_flags, env=env, extra_args=extra_args, base_config_dir=base_config_dir, default_config_dir=default_config_dir, user_config_dir=user_config_dir, default_fee_limit=default_fee_limit, logger=logger, load_callback=load_callback) if not config.get('RPC_DIALECT'): diff --git a/chainlib/eth/gas.py b/chainlib/eth/gas.py index da0c73f..8295c73 100644 --- a/chainlib/eth/gas.py +++ b/chainlib/eth/gas.py @@ -244,7 +244,7 @@ class OverrideGasOracle(RPCGasOracle): else: fee_units = MINIMUM_FEE_UNITS logg.debug('override gas oracle without explicit limit, setting default {}'.format(fee_units)) - + return (fee_price, fee_units) diff --git a/setup.cfg b/setup.cfg index d806605..60c64b7 100644 --- a/setup.cfg +++ b/setup.cfg @@ -1,6 +1,6 @@ [metadata] name = chainlib-eth -version = 0.0.9a6 +version = 0.0.9a7 description = Ethereum implementation of the chainlib interface author = Louis Holbrook author_email = dev@holbrook.no