1
0

daemon: get_wallet: handle OSError for weiiird paths

I think _wallet_key_from_path should not raise.
This is probably the sane way to deal with this.
Though all this is assuming that os.path.realpath can be treated as consistent/stateless.

closes https://github.com/spesmilo/electrum/issues/10182
This commit is contained in:
SomberNight
2025-09-03 14:14:22 +00:00
parent 4a0a3bb38a
commit c68deb25ff
2 changed files with 7 additions and 3 deletions

View File

@@ -38,7 +38,7 @@ class QEWalletListModel(QAbstractListModel):
_ROLE_KEYS = range(Qt.ItemDataRole.UserRole, Qt.ItemDataRole.UserRole + len(_ROLE_NAMES))
_ROLE_MAP = dict(zip(_ROLE_KEYS, [bytearray(x.encode()) for x in _ROLE_NAMES]))
def __init__(self, daemon, parent=None):
def __init__(self, daemon: 'Daemon', parent=None):
QAbstractListModel.__init__(self, parent)
self.daemon = daemon
self._wallets = []