commit 677b7426905ef3cbf204706bb9323999eb05d8c5
parent 96a0f3beb04170167859a2fce25d59b90929479a
Author: lash <dev@holbrook.no>
Date: Fri, 21 Jan 2022 00:14:31 +0000
Bring in loglevel changes in chainlib, bump version
Diffstat:
4 files changed, 10 insertions(+), 3 deletions(-)
diff --git a/CHANGELOG b/CHANGELOG
@@ -1,3 +1,8 @@
+- 0.0.19:
+ * Add delay on eth-wait cli tool
+
+(changelog incomplete below here)
+
- 0.0.15:
* Correct inverted addess checksum check for gas cli
- 0.0.5-unreleased:
diff --git a/chainlib/eth/runnable/wait.py b/chainlib/eth/runnable/wait.py
@@ -51,6 +51,7 @@ config_dir = os.path.join(script_dir, '..', 'data', 'config')
arg_flags = chainlib.eth.cli.argflag_std_read
argparser = chainlib.eth.cli.ArgumentParser(arg_flags)
+argparser.add_argument('--delay', type=float, default=0.5, help='Delay between polls')
argparser.add_argument('--ignore', type=str, action='append', default=[], help='Ignore error from the given transaction')
argparser.add_argument('--ignore-all', action='store_true', dest='ignore_all', help='Ignore errors from all transactions')
argparser.add_positional('hashes', append=True, type=str, help='Transaction hashes to wait for')
@@ -59,6 +60,7 @@ extra_args = {
'ignore': None,
'ignore_all': None,
'hashes': None,
+ 'delay': None,
}
config = chainlib.eth.cli.Config.from_args(args, arg_flags, extra_args=extra_args, default_config_dir=config_dir)
@@ -99,7 +101,7 @@ def main():
for hsh in hashes_ready:
logg.debug('processing transaction hash {}'.format(hsh))
try:
- r = conn.wait(hsh)
+ r = conn.wait(hsh, delay=config.get('_DELAY'))
except RevertEthException:
if config.get('_IGNORE_ALL') or hsh in hashes_ignore:
logg.info('ignoring revert in transaction hash {}'.format(hsh))
diff --git a/requirements.txt b/requirements.txt
@@ -3,5 +3,5 @@ pysha3==1.0.2
hexathon~=0.1.1
websocket-client==0.57.0
potaahto~=0.1.0
-chainlib~=0.0.16
+chainlib~=0.0.17
confini~=0.5.2
diff --git a/setup.cfg b/setup.cfg
@@ -1,6 +1,6 @@
[metadata]
name = chainlib-eth
-version = 0.0.18
+version = 0.0.20
description = Ethereum implementation of the chainlib interface
author = Louis Holbrook
author_email = dev@holbrook.no