Compare commits

...

2 Commits

6 changed files with 15 additions and 15 deletions

View File

@ -1,3 +1,8 @@
- 0.8.6
* Handle crash on conrtact creation when recipient filter is active
- 0.8.5
* Instantiate constructor for chain interface superclass
* Remove unused settings transform method for sync interface
- 0.8.4
* Update man pages with rpc batch limit setting
- 0.8.3

View File

@ -8,15 +8,19 @@ from chainlib.eth.block import (
from chainlib.eth.tx import (
receipt,
Tx,
transaction,
)
class EthChainInterface(ChainInterface):
def __init__(self, dialect_filter=None, batch_limit=1):
super(EthChainInterface, self).__init__(dialect_filter=dialect_filter, batch_limit=batch_limit)
self.batch_limit = batch_limit
self._block_latest = block_latest
self._block_by_number = block_by_number
self._block_from_src = Block.from_src
self._tx_from_src = Tx.from_src
self._tx_receipt = receipt
self._src_normalize = Tx.src_normalize
self._dialect_filter = dialect_filter
self._tx_by_hash = transaction

View File

@ -85,6 +85,8 @@ class RuleSimple:
if rule != None and is_same_address(sender, rule):
logg.debug('tx {} rule {} match in SENDER {}'.format(tx_hash, self.description, sender))
return True
if recipient == None:
return False
for rule in self.inputs:
if rule != None and is_same_address(recipient, rule):
logg.debug('tx {} rule {} match in RECIPIENT {}'.format(tx_hash, self.description, recipient))

View File

@ -356,22 +356,11 @@ def process_cache_rpc(settings, config):
return settings
def process_sync_interface(settings, config):
ifc = EthChainInterface(dialect=settings.get('RPC_DIALECT_FILTER'))
settings.set('SYNCER_INTERFACE', ifc)
return settings
def process_sync(settings, config):
dialect_filter = settings.get('RPC_DIALECT_FILTER')
settings.set('SYNCER_INTERFACE', EthChainInterface(dialect_filter=dialect_filter, batch_limit=settings.get('RPC_BATCH_LIMIT')))
settings = process_sync_range(settings, config)
return settings
#def process_sync(settings, config):
# settings = process_sync_interface(settings, config)
# settings = process_sync_backend(settings, config)
# settings = process_sync_range(settings, config)
# return settings
def process_cache(settings, config):

View File

@ -1,6 +1,6 @@
chainlib-eth~=0.5.0
chainlib~=0.5.1
chainsyncer~=0.8.2
chainlib-eth~=0.5.1
chainlib~=0.5.2
chainsyncer~=0.8.3
leveldir~=0.3.0
eth-cache~=0.3.0
confini~=0.6.3

View File

@ -1,6 +1,6 @@
[metadata]
name = eth-monitor
version = 0.8.4
version = 0.8.6
description = Monitor and cache transactions using match filters
author = Louis Holbrook
author_email = dev@holbrook.no