storj-archived / storj-python-sdk

Deprecated. A Python SDK for the Storj API.
https://storj.io
MIT License
23 stars 19 forks source link

model.Keypair #63

Closed steenzout closed 7 years ago

steenzout commented 7 years ago

61 + increased test coverage, consistent docstring and more Pythonic approach.

@Miskerest please review.

thank you!

coveralls commented 7 years ago

Coverage Status

Coverage increased (+0.3%) to 72.754% when pulling 9132f4a117e6f96f52a9df1115efc5c7673f9f8f on steenzout:pull_61 into 0b9741bfeed9127a0a23101868abe0243f73250d on Storj:master.

steenzout commented 7 years ago

pycoin is not Python 3.x compatible.

storj/model.py:220: in __init__
    self.keypair = BIP32Node.from_master_secret(secret)
.tox/py35/lib/python3.5/site-packages/pycoin/key/BIP32Node.py:67: in from_master_secret
    I64 = hmac.HMAC(key=b"Bitcoin seed", msg=master_secret, digestmod=hashlib.sha512).digest()
.tox/py35/lib/python3.5/hmac.py:84: in __init__
    self.update(msg)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
self = <hmac.HMAC object at 0x7f76be808a20>, msg = 'master_password'
    def update(self, msg):
        """Update this hashing object with the string msg.
            """
>       self.inner.update(msg)
E       TypeError: Unicode-objects must be encoded before hashing
.tox/py35/lib/python3.5/hmac.py:93: TypeError
steenzout commented 7 years ago

sync'ed with #61 . pycoin doesn't support Python3 so removed that classifier and allowed tests to fail.

steenzout commented 7 years ago

@BlackDuck888 ping.

coveralls commented 7 years ago

Coverage Status

Coverage increased (+0.3%) to 72.754% when pulling b8dd43a54d4027acc249305f421389eccf4b6020 on steenzout:pull_61 into 0b9741bfeed9127a0a23101868abe0243f73250d on Storj:master.

steenzout commented 7 years ago

closed by #64