Skip to content
This repository has been archived by the owner on Apr 12, 2022. It is now read-only.

Commit

Permalink
Fix some lint errors
Browse files Browse the repository at this point in the history
There are still two lint errors. They will take more effort.

Signed-off-by: Boyd Johnson <bjohnson@bitwise.io>
  • Loading branch information
Boyd Johnson authored and boydjohnson committed Dec 27, 2017
1 parent ff63062 commit d879806
Show file tree
Hide file tree
Showing 4 changed files with 12 additions and 9 deletions.
14 changes: 8 additions & 6 deletions addressing/marketplace_addressing/addresser.py
Expand Up @@ -128,18 +128,20 @@ def address_is(address):
infix = int(address[6:8], 16)

if _contains(infix, OfferHistorySpace):
return AddressSpace.OFFER_HISTORY
result = AddressSpace.OFFER_HISTORY

elif _contains(infix, AssetSpace):
return AddressSpace.ASSET
result = AddressSpace.ASSET

elif _contains(infix, HoldingSpace):
return AddressSpace.HOLDING
result = AddressSpace.HOLDING

elif _contains(infix, AccountSpace):
return AddressSpace.ACCOUNT
result = AddressSpace.ACCOUNT

elif _contains(infix, OfferSpace):
return AddressSpace.OFFER
result = AddressSpace.OFFER
else:
return AddressSpace.OTHER_FAMILY
result = AddressSpace.OTHER_FAMILY

return result
2 changes: 1 addition & 1 deletion dev_env/Dockerfile
Expand Up @@ -33,7 +33,7 @@ RUN curl -sL https://deb.nodesource.com/setup_6.x | bash - \
&& apt-get install -y nodejs

RUN pip3 install \
pylint==1.7.4 \
pylint==1.8.1 \
pycodestyle==2.3.1 \
grpcio-tools==1.7.0 \
nose2==0.7.2 \
Expand Down
2 changes: 1 addition & 1 deletion ledger_sync/marketplace_ledger_sync/deltas/decoding.py
Expand Up @@ -39,7 +39,7 @@ def data_to_dicts(address, data):
"""
data_type = address_is(address)

if (IGNORE.get(data_type)):
if IGNORE.get(data_type):
return []

try:
Expand Down
3 changes: 2 additions & 1 deletion ledger_sync/marketplace_ledger_sync/deltas/handlers.py
Expand Up @@ -16,9 +16,10 @@
import re
import logging

from sawtooth_sdk.protobuf.transaction_receipt_pb2 import StateChangeList

from marketplace_ledger_sync.deltas.decoding import data_to_dicts
from marketplace_ledger_sync.deltas.updating import get_updater
from sawtooth_sdk.protobuf.transaction_receipt_pb2 import StateChangeList
from marketplace_addressing.addresser import NS as NAMESPACE


Expand Down

0 comments on commit d879806

Please sign in to comment.