Skip to content

Commit

Permalink
Merge pull request #74 from ltonetwork/no-pyblake2
Browse files Browse the repository at this point in the history
Remove dependency on pysha3 and pyblake2.
  • Loading branch information
jasny authored Oct 4, 2024
2 parents 47a3a03 + 69957ce commit 2a54ced
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 6 deletions.
4 changes: 2 additions & 2 deletions .travis.yml
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
---
language: python
dist: jammy

python:
- 3.9.7
- 3.9
- 3.8

branches:
Expand Down
2 changes: 0 additions & 2 deletions setup.cfg
Original file line number Diff line number Diff line change
Expand Up @@ -24,15 +24,13 @@ python_requires = >=3.8
install_requires =
requests>=2.24.0, <3
PyNaCl
pyblake2~=1.1.0
base58~=0.2.5
ecdsa~=0.17.0
inflection~=0.5.1
freezegun~=1.1.0
mnemonic~=0.20
eth-utils~=2.0.0
pycryptodome~=3.12.0
pysha3~=1.0.2

[options.packages.find]
where = src
3 changes: 1 addition & 2 deletions src/lto/crypto.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
import base64
import hashlib
import pyblake2
import base58
import inflection

Expand All @@ -14,7 +13,7 @@ def sha256(s):


def hash_chain(s):
a = pyblake2.blake2b(s, digest_size=32).digest()
a = hashlib.blake2b(s, digest_size=32).digest()
b = hashlib.sha256(a).digest()
return ''.join(map(chr, b))

Expand Down

0 comments on commit 2a54ced

Please sign in to comment.