typing and pylint fixes

This commit is contained in:
Lex Berezhny 2018-09-25 18:14:28 -04:00
parent c29b4c476d
commit 0d22b8c23c

View file

@ -138,7 +138,7 @@ class BaseInput(InputOutput):
return self.txo_ref.txo.amount
@property
def is_my_account(self) -> int:
def is_my_account(self) -> Optional[bool]:
""" True if the output this input spends is yours. """
if self.txo_ref.txo is None:
raise ValueError('Cannot resolve output to determine ownership.')
@ -237,8 +237,8 @@ class BaseTransaction:
input_class = BaseInput
output_class = BaseOutput
def __init__(self, raw=None, version: int=1, locktime: int=0,
height: int=-1, position: int=-1) -> None:
def __init__(self, raw=None, version: int = 1, locktime: int = 0,
height: int = -1, position: int = -1) -> None:
self._raw = raw
self.ref = TXRefMutable(self)
self.version = version