-
Notifications
You must be signed in to change notification settings - Fork 178
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Use get_deser_from_gettransaction() everywhere
- Loading branch information
Showing
1 changed file
with
4 additions
and
4 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -384,8 +384,8 @@ def get_tx_info(txid: str, tx_cache: Optional[dict] = None) -> Tuple[ | |
rpctx, rpctx_deser = tx_cache[txid] | ||
else: | ||
rpctx = jm_single().bc_interface.get_transaction(txid) | ||
txhex = str(rpctx['hex']) | ||
rpctx_deser = btc.CMutableTransaction.deserialize(hextobin(txhex)) | ||
rpctx_deser = jm_single().bc_interface.get_deser_from_gettransaction( | ||
rpctx) | ||
if tx_cache is not None: | ||
tx_cache[txid] = (rpctx, rpctx_deser) | ||
output_script_values = {x.scriptPubKey: x.nValue for x in rpctx_deser.vout} | ||
|
@@ -912,8 +912,8 @@ def print_row(index, time, tx_type, amount, delta, balance, cj_n, | |
wallet_tx = jm_single().bc_interface.get_transaction( | ||
ins.prevout.hash[::-1]) | ||
if wallet_tx: | ||
wallet_tx_deser = btc.CMutableTransaction.deserialize( | ||
hextobin(wallet_tx['hex'])) | ||
wallet_tx_deser = jm_single.bc_interface( | ||
This comment has been minimized.
Sorry, something went wrong.
This comment has been minimized.
Sorry, something went wrong.
kristapsk
Author
Member
|
||
).get_deser_from_gettransaction(wallet_tx) | ||
tx_cache[ins.prevout.hash[::-1]] = (wallet_tx, | ||
wallet_tx_deser) | ||
if wallet_tx is None: | ||
|
@kristapsk: I think this should have been
jm_single()
, notjm_single
. I am getting this exception: