iceland2k14/secp256k1

Pypy3 issue with hash160 address

telekall opened this issue · 4 comments

Hi there:
Quick question.
I am using this library with pypy3 and seems to work fine with compress and uncompress btc address.
But when try something like that:
mykey = int(key,16)
hash160 = ice.privatekey_to_h160(0, True, mykey).hex()
print(hash160)
I just got only 40 zeros = 0000000000000000000000000000000000000000
Can you spot a solution, thanks!

Can you tell me what was the key for which it is happening. Or is it a secret ??

hi,
The key is just a decimal number like :18446744073709551616.
Again, works fine with pure python, but with pypy3 just got a bunch of zeros.

pypy and pypy3 doesn't support ctypes and finite fields operations. And pure python with ctypes is faster, than pypy.

If you want use pypy, use this with pure python scripts or with cffi.

Hi there: Quick question. I am using this library with pypy3 and seems to work fine with compress and uncompress btc address. But when try something like that: mykey = int(key,16) hash160 = ice.privatekey_to_h160(0, True, mykey).hex() print(hash160) I just got only 40 zeros = 0000000000000000000000000000000000000000 Can you spot a solution, thanks!

pypy no work with DLL !