From 69cff972013c698a4b65adc6c58d6c72649edd74 Mon Sep 17 00:00:00 2001 From: The MMGen Project Date: Wed, 16 Mar 2022 14:58:09 +0000 Subject: [PATCH] mmgen-xmrwallet: add timestamp to address labels --- mmgen/xmrwallet.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/mmgen/xmrwallet.py b/mmgen/xmrwallet.py index 13b66423..14a788d3 100755 --- a/mmgen/xmrwallet.py +++ b/mmgen/xmrwallet.py @@ -455,7 +455,7 @@ class MoneroWalletOps: msg('\n Creating new account...') ret = await self.c.call( 'create_account', - label = f'Sweep from {self.parent.source.idx}:{self.parent.account}' + label = f'Sweep from {self.parent.source.idx}:{self.parent.account} [{make_timestr()}]' ) msg(' Index: {}'.format( pink(str(ret['account_index'])) )) msg(' Address: {}'.format( cyan(ret['address']) )) @@ -474,7 +474,7 @@ class MoneroWalletOps: msg('\n Addresses of account #{} ({}):'.format( account, accts_data['subaddress_accounts'][account]['label'])) - fs = ' {:6} {:18} {:%s} {}' % max(len(e['label']) for e in d) + fs = ' {:6} {:18} {:%s} {}' % max( [len(e['label']) for e in d], default=0 ) msg(fs.format('Index ','Address','Label','Used')) for e in d: msg(fs.format( @@ -489,7 +489,7 @@ class MoneroWalletOps: ret = await self.c.call( 'create_address', account_index = account, - label = 'Sweep from this account', + label = f'Sweep from this account [{make_timestr()}]', ) msg(cyan(ret['address'])) return ret['address']