electrum

Electrum Bitcoin wallet
git clone https://git.parazyd.org/electrum
Log | Files | Refs | Submodules

commit 9dde9971da83f146e30f7685a70578cfb3351372
parent ddcdbfa181b74f1fb62666d48fdb40904bea8d0a
Author: ThomasV <thomasv@electrum.org>
Date:   Thu,  2 Mar 2017 11:10:28 +0100

do not revert to static fee when dynamic fee estimates are missing

Diffstat:
Mgui/qt/main_window.py | 4++++
Mlib/simple_config.py | 2+-
2 files changed, 5 insertions(+), 1 deletion(-)

diff --git a/gui/qt/main_window.py b/gui/qt/main_window.py @@ -277,6 +277,7 @@ class ElectrumWindow(QMainWindow, MessageBoxMixin, PrintError): elif event == 'fee': if self.config.is_dynfee(): self.fee_slider.update() + self.do_update_fee() else: self.print_error("unexpected network_qt signal:", event, args) @@ -1114,6 +1115,9 @@ class ElectrumWindow(QMainWindow, MessageBoxMixin, PrintError): '''Recalculate the fee. If the fee was manually input, retain it, but still build the TX to see if there are enough funds. ''' + if self.config.is_dynfee() and not self.config.has_fee_estimates(): + self.statusBar().showMessage(_('Waiting for fee estimates...')) + return False freeze_fee = (self.fee_e.isModified() and (self.fee_e.text() or self.fee_e.hasFocus())) amount = '!' if self.is_max else self.amount_e.get_amount() diff --git a/lib/simple_config.py b/lib/simple_config.py @@ -222,7 +222,7 @@ class SimpleConfig(PrintError): return len(self.fee_estimates)==4 def is_dynfee(self): - return self.get('dynamic_fees') and self.has_fee_estimates() + return self.get('dynamic_fees') def fee_per_kb(self): dyn = self.is_dynfee()