fixes https://github.com/spesmilo/electrum/issues/8240#8240 was triggering an AssertionError in wallet.get_invoice_status,
as code there was assuming conf >= 0. To trigger, force-close
a LN channel, and while the sweep is waiting on the CSV, try to
make a payment in the Send tab to the ismine change address used
for the sweep in the future_tx. (order of events can also be reversed)
That way, users can see the effects settings directly on their transaction.
This changes the API of make_tx:
- get_coins is called inside make_tx, so that inputs can be changed dynamically
- make_tx takes an optional parameter: unconfirmed_only, passed to get_coins
- ConfirmTxDialog detects if we can pay by disabling confirmed_only or lowering fee
follow-up 719b468eee
Traceback (most recent call last):
File "...\electrum\electrum\gui\qt\history_list.py", line 673, in mouseDoubleClickEvent
self.parent.show_lightning_transaction(tx_item)
File "...\electrum\electrum\gui\qt\main_window.py", line 1082, in show_lightning_transaction
d = LightningTxDialog(self, tx_item)
File "...\electrum\electrum\gui\qt\lightning_tx_dialog.py", line 60, in __init__
self.invoice = invoice.lightning_invoice
AttributeError: 'Request' object has no attribute 'lightning_invoice'
Traceback (most recent call last):
File "/home/user/wspace/electrum/electrum/gui/qt/transaction_dialog.py", line 255, in _open_internal_link
self.main_window.do_process_from_txid(txid=target, parent=self)
File "/home/user/wspace/electrum/electrum/gui/qt/main_window.py", line 2212, in do_process_from_txid
self.show_transaction(tx)
File "/home/user/wspace/electrum/electrum/gui/qt/main_window.py", line 1079, in show_transaction
show_transaction(tx, parent=self, desc=tx_desc)
File "/home/user/wspace/electrum/electrum/gui/qt/transaction_dialog.py", line 351, in show_transaction
d = TxDialog(tx, parent=parent, desc=desc, prompt_if_unsaved=prompt_if_unsaved)
File "/home/user/wspace/electrum/electrum/gui/qt/transaction_dialog.py", line 449, in __init__
self.update()
File "/home/user/wspace/electrum/electrum/gui/qt/transaction_dialog.py", line 667, in update
tx_mined_status = self.wallet.lnworker.lnwatcher.adb.get_tx_height(txid)
AttributeError: 'NoneType' object has no attribute 'adb'
- add a new event, 'adb_removed_tx'
- new wallet method: get_tx_parents
- number of parents is shown in coins tab
- detailed list of parents is shown in dialog
```
629.08 | E | gui.qt.exception_window.Exception_Hook | exception caught by crash reporter
Traceback (most recent call last):
File ".../electrum/electrum/gui/qt/invoice_list.py", line 170, in <lambda>
menu.addAction(_("Pay") + "...", lambda: self.send_tab.do_pay_invoice(invoice))
File ".../electrum/electrum/gui/qt/send_tab.py", line 573, in do_pay_invoice
self.pay_onchain_dialog(self.window.get_coins(), invoice.outputs)
File ".../electrum/electrum/gui/qt/send_tab.py", line 251, in pay_onchain_dialog
self.window.show_transaction(tx)
File ".../electrum/electrum/gui/qt/main_window.py", line 1074, in show_transaction
show_transaction(tx, parent=self, desc=tx_desc)
File ".../electrum/electrum/gui/qt/transaction_dialog.py", line 351, in show_transaction
d = TxDialog(tx, parent=parent, desc=desc, prompt_if_unsaved=prompt_if_unsaved)
File ".../electrum/electrum/gui/qt/transaction_dialog.py", line 450, in __init__
self.set_title()
File ".../electrum/electrum/gui/qt/transaction_dialog.py", line 858, in set_title
self.setWindowTitle(_("Transaction") + ' ' + self.tx.txid())
TypeError: can only concatenate str (not "NoneType") to str
```
- send to address
- in new channel
- in submarine swap
This is easier than coin control, because it does not involve
switching tabs. Coin control is activated during the operation,
so that users learn how it works.