From 7e84aed9c22dc4117f371c7c4c953408988c1dbb Mon Sep 17 00:00:00 2001 From: Sander van Grieken Date: Tue, 28 Feb 2023 14:32:26 +0100 Subject: [PATCH] qml: log and reraise any exceptions in the constructor of QEAbstractInvoiceListModel, so we at least see the root cause of the confusing AttributeError: 'QEWallet' object has no attribute 'requestModel' --- electrum/gui/qml/qeinvoicelistmodel.py | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/electrum/gui/qml/qeinvoicelistmodel.py b/electrum/gui/qml/qeinvoicelistmodel.py index 16b918f77..f5f53a8db 100644 --- a/electrum/gui/qml/qeinvoicelistmodel.py +++ b/electrum/gui/qml/qeinvoicelistmodel.py @@ -29,7 +29,11 @@ class QEAbstractInvoiceListModel(QAbstractListModel): self._timer.setSingleShot(True) self._timer.timeout.connect(self.updateStatusStrings) - self.init_model() + try: + self.init_model() + except Exception as e: + self._logger.error(f'{repr(e)}') + raise e def rowCount(self, index): return len(self.invoices)