From ce8f564fb48d2aa0d22a1d6162ed165e4ea9f4f3 Mon Sep 17 00:00:00 2001 From: SomberNight Date: Thu, 20 Apr 2023 00:36:40 +0000 Subject: [PATCH] qt bump fee: disable targeting an abs fee. only allow setting feerate wallet.bump_fee() only allows targeting a feerate. Prior to this commit, _BaseRBFDialog(TxEditor) allowed setting either a feerate or an abs fee. When setting an abs fee, TxEditor.update_fee_fields() tries to adjust the feerate accordingly, and then via side-effecting, wallet.bump_fee() will get called with the derived feerate. This seems really buggy atm. I think it is best to disable setting abs fees, and if we want to enable it later, targeting needs to be implemented in wallet.bump_fee() - just like how it works in ConfirmTxDialog(TxEditor) and wallet.make_unsigned_transaction(). --- electrum/gui/qt/rbf_dialog.py | 1 + 1 file changed, 1 insertion(+) diff --git a/electrum/gui/qt/rbf_dialog.py b/electrum/gui/qt/rbf_dialog.py index 045413e9b..97c34cabc 100644 --- a/electrum/gui/qt/rbf_dialog.py +++ b/electrum/gui/qt/rbf_dialog.py @@ -49,6 +49,7 @@ class _BaseRBFDialog(TxEditor): title=title, make_tx=self.rbf_func) + self.fee_e.setFrozen(True) # disallow setting absolute fee for now, as wallet.bump_fee can only target feerate new_fee_rate = self.old_fee_rate + max(1, self.old_fee_rate // 20) self.feerate_e.setAmount(new_fee_rate) self.update()