-
Notifications
You must be signed in to change notification settings - Fork 432
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
ImportError: cannot import name 'generator_secp256k1' #52
Comments
@susil-mohanty Seems the example code is outdated w/ the from pycoin.ecdsa.secp256k1 import secp256k1_generator
def sign_ecdsa_secp256k1(msg, priv_key):
return secp256k1_generator.sign(priv_key, sha3_256(msg))
def verify_ecdsa_secp256k1(msg, sig, pub_key):
return secp256k1_generator.verify(pub_key, sha3_256(msg), sig) |
ImportError Traceback (most recent call last) ImportError: cannot import name 'sign', 'verify' Same error is coming for sign and verify... |
Im getting the same error... |
I got the similar error as well 😢 |
Just install https://github.com/richardkiss/pycoin/releases/tag/0.70 it should work fine. |
You can try install the below version, it works for me. pip install pycoin==0.70 |
from pycoin.ecdsa import generator_secp256k1, sign, verify
import hashlib, secrets
ImportError Traceback (most recent call last)
in
----> 1 from pycoin.ecdsa import generator_secp256k1, sign, verify
2 import hashlib, secrets
3
4 def sha3_256Hash(msg):
5 hashBytes = hashlib.sha3_256(msg.encode("utf8")).digest()
ImportError: cannot import name 'generator_secp256k1'
The text was updated successfully, but these errors were encountered: