From 814c3c08b2e557e026edb093beb00a03bf59c650 Mon Sep 17 00:00:00 2001 From: Charles Cooper Date: Fri, 15 Mar 2019 11:43:34 -0700 Subject: [PATCH] Fix lint --- tests/core/filtering/test_contract_getLogs.py | 6 ++++-- web3/contract.py | 4 ++-- 2 files changed, 6 insertions(+), 4 deletions(-) diff --git a/tests/core/filtering/test_contract_getLogs.py b/tests/core/filtering/test_contract_getLogs.py index 85af4836c1..360a172021 100644 --- a/tests/core/filtering/test_contract_getLogs.py +++ b/tests/core/filtering/test_contract_getLogs.py @@ -83,13 +83,15 @@ def test_contract_getLogs_argument_filter( assert len(all_logs) == 4 # Filter all entries where arg1 in (1, 2) - partial_logs = contract.events.LogTripleWithIndex.getLogs(fromBlock=1, + partial_logs = contract.events.LogTripleWithIndex.getLogs( + fromBlock=1, argument_filters={'arg1': [1, 2]}, ) assert len(partial_logs) == 2 # Filter all entries where arg0 == 1 - partial_logs = contract.events.LogTripleWithIndex.getLogs(fromBlock=1, + partial_logs = contract.events.LogTripleWithIndex.getLogs( + fromBlock=1, argument_filters={'arg0': 1}, ) assert len(partial_logs) == 4 diff --git a/web3/contract.py b/web3/contract.py index 2743116709..6138bb7c17 100644 --- a/web3/contract.py +++ b/web3/contract.py @@ -1133,8 +1133,8 @@ def getLogs(self, blknum_set = fromBlock is not None or toBlock is not None if blkhash_set and blknum_set: raise ValidationError( - 'blockHash cannot be set at the same' - ' time as fromBlock or toBlock') + 'blockHash cannot be set at the same' + ' time as fromBlock or toBlock') # Construct JSON-RPC raw filter presentation based on human readable Python descriptions # Namely, convert event names to their keccak signatures