Skip to content

Commit

Permalink
Fix example
Browse files Browse the repository at this point in the history
  • Loading branch information
ebellocchia committed May 4, 2024
1 parent 0e8bbbb commit 021cf8b
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions examples/bip32_slip10_nist256p1.py
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
"""Example of keys derivation using BIP32 (nist256p1 curve)."""

from bip_utils import (
Bip32Slip10Nist256p1, Bip39MnemonicGenerator, Bip39SeedGenerator, Bip39WordsNum, CoinsConf, NeoAddr
Bip32Slip10Nist256p1, Bip39MnemonicGenerator, Bip39SeedGenerator, Bip39WordsNum, CoinsConf, NeoLegacyAddrEncoder
)


Expand All @@ -27,6 +27,6 @@

# Print address in NEO encoding
# The BIP32 elliptic curve shall be the same one expected by NEO (nist256p1 in this case)
neo_addr = NeoAddr.EncodeKey(bip32_der_ctx.PublicKey().KeyObject(),
ver=CoinsConf.Neo.ParamByKey("addr_ver"))
neo_addr = NeoLegacyAddrEncoder.EncodeKey(bip32_der_ctx.PublicKey().KeyObject(),
ver=CoinsConf.Neo.ParamByKey("addr_ver"))
print(f"Address (NEO): {neo_addr}")

0 comments on commit 021cf8b

Please sign in to comment.