qt: ElectrumGui: repr(UserFacingException) -> str()

Show UserFacingException in ElectrumGui.start_new_window
as str() to the user, ther doesn't seem to be a good reason
to show its repr?
This commit is contained in:
f321x
2026-03-23 10:14:31 +01:00
parent 543b73be9b
commit 2c541d2663
+1 -2
View File
@@ -413,11 +413,10 @@ class ElectrumGui(BaseElectrumGui, Logger):
self.logger.exception('')
if isinstance(e, UserFacingException) \
or isinstance(e, WalletFileException) and not e.should_report_crash:
err_text = str(e) if isinstance(e, WalletFileException) else repr(e)
custom_message_box(icon=QMessageBox.Icon.Warning,
parent=None,
title=_('Error'),
text=_('Cannot load wallet') + '(2) :\n' + err_text)
text=_('Cannot load wallet') + '(2) :\n' + str(e))
else:
send_exception_to_crash_reporter(e)
if app_is_starting: