Browse Source

Merge #489: Display confirmations in wallet-tool showutxos

f891bcb Display confirmations in wallet-tool showutxos (chris-belcher)

Tree-SHA512: 43094ecf8d47212a71982118a946346dd7e248f19dba6a2a5164dea851c276d4405c600d611a6e6f8916870469486881bf0de8bb876af03ec4eaa4093ec70a6d
master
chris-belcher 6 years ago
parent
commit
786e4c9690
No known key found for this signature in database
GPG Key ID: EF734EA677F31129
  1. 5
      jmclient/jmclient/wallet_utils.py

5
jmclient/jmclient/wallet_utils.py

@ -353,7 +353,7 @@ def get_imported_privkey_branch(wallet_service, m, showprivkey):
def wallet_showutxos(wallet, showprivkey): def wallet_showutxos(wallet, showprivkey):
unsp = {} unsp = {}
max_tries = jm_single().config.getint("POLICY", "taker_utxo_retries") max_tries = jm_single().config.getint("POLICY", "taker_utxo_retries")
utxos = wallet.get_utxos_by_mixdepth() utxos = wallet.get_utxos_by_mixdepth(includeconfs=True)
for md in utxos: for md in utxos:
for u, av in utxos[md].items(): for u, av in utxos[md].items():
key = wallet.get_key_from_addr(av['address']) key = wallet.get_key_from_addr(av['address'])
@ -361,7 +361,8 @@ def wallet_showutxos(wallet, showprivkey):
tries_remaining = max(0, max_tries - tries) tries_remaining = max(0, max_tries - tries)
unsp[u] = {'address': av['address'], 'value': av['value'], unsp[u] = {'address': av['address'], 'value': av['value'],
'tries': tries, 'tries_remaining': tries_remaining, 'tries': tries, 'tries_remaining': tries_remaining,
'external': False} 'external': False,
'confirmations': av['confs']}
if showprivkey: if showprivkey:
unsp[u]['privkey'] = wallet.get_wif_path(av['path']) unsp[u]['privkey'] = wallet.get_wif_path(av['path'])

Loading…
Cancel
Save