From d86cbee2ded1f74cacafa4616b5a79e179c4cb21 Mon Sep 17 00:00:00 2001 From: Jude Nelson Date: Thu, 4 Aug 2016 15:42:51 -0400 Subject: [PATCH] use virtualchain's key logic --- blockstack/lib/nameset/virtualchain_hooks.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/blockstack/lib/nameset/virtualchain_hooks.py b/blockstack/lib/nameset/virtualchain_hooks.py index ea64b4760..5bd4c2476 100644 --- a/blockstack/lib/nameset/virtualchain_hooks.py +++ b/blockstack/lib/nameset/virtualchain_hooks.py @@ -100,7 +100,7 @@ def get_public_key_hex_from_tx( inputs, address ): pubkey = None try: - pubkey = pybitcoin.BitcoinPublicKey( str(pubkey_hex) ) + pubkey = virtualchain.BitcoinPublicKey( str(pubkey_hex) ) except Exception, e: traceback.print_exc() log.warning("Invalid public key '%s'" % pubkey_hex) @@ -425,7 +425,7 @@ def db_parse( block_id, txid, vtxindex, opcode, data, senders, inputs, outputs, # these operations have a designated recipient that is *not* the sender try: recipient = get_registration_recipient_from_outputs( outputs ) - recipient_address = pybitcoin.script_hex_to_address( recipient ) + recipient_address = virtualchain.script_hex_to_address( recipient ) except Exception, e: log.exception(e) raise Exception("No registration address for (%s, %s)" % (opcode, hexlify(data))) @@ -435,7 +435,7 @@ def db_parse( block_id, txid, vtxindex, opcode, data, senders, inputs, outputs, # these operations have a designated recipient that is *not* the sender try: recipient = get_transfer_recipient_from_outputs( outputs ) - recipient_address = pybitcoin.script_hex_to_address( recipient ) + recipient_address = virtualchain.script_hex_to_address( recipient ) except Exception, e: log.exception(e) raise Exception("No recipient for (%s, %s)" % (opcode, hexlify(data)))