commit b36e9a64512000e77ea682c041389b6326b70032
parent fbf6af5d07691f35f0b5cd4c5705a0845cfa9cc4
Author: ThomasV <thomasv@electrum.org>
Date: Fri, 6 Mar 2020 13:35:05 +0100
Qt: add info about force closing
Diffstat:
1 file changed, 7 insertions(+), 1 deletion(-)
diff --git a/electrum/gui/qt/channels_list.py b/electrum/gui/qt/channels_list.py
@@ -98,10 +98,16 @@ class ChannelsList(MyTreeView):
WaitingDialog(self, 'please wait..', task, self.on_success, self.on_failure)
def force_close(self, channel_id):
+ chan = self.lnworker.channels[channel_id]
+ to_self_delay = chan.config[REMOTE].to_self_delay
if self.lnworker.wallet.is_lightning_backup():
msg = _('WARNING: force-closing from an old state might result in fund loss.\nAre you sure?')
else:
- msg = _('Force-close channel?\nReclaimed funds will not be immediately available.')
+ msg = _('Force-close channel?') + '\n\n'\
+ + _(f'Funds retrieved from this channel will not be available before {to_self_delay} blocks after forced closure.') + ' '\
+ + _('After that delay, funds will be sent to an address derived from your wallet seed.') + '\n\n'\
+ + _('In the meantime, channel funds will not be recoverable from your seed, and will be lost if you lose your wallet.') + ' '\
+ + _('To avoid that, you should backup your wallet after you force close the channel.')
if self.parent.question(msg):
def task():
coro = self.lnworker.force_close_channel(channel_id)