From b926d56be2e5d8f9e9310d413efa2457f680dbb8 Mon Sep 17 00:00:00 2001 From: Angelo Naselli Date: Sun, 17 Nov 2024 16:37:19 +0100 Subject: [PATCH] Avoided to die for a transaction warning and added a Warning dialog. Be aware that the transaction is not cleaned though --- dnfdragora/ui.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/dnfdragora/ui.py b/dnfdragora/ui.py index 3ffa009..bfdbae1 100644 --- a/dnfdragora/ui.py +++ b/dnfdragora/ui.py @@ -2272,9 +2272,10 @@ def _OnBuildTransaction(self, info): if result == 1: #Transaction WARNING errors = self.backend.TransactionProblems(sync=True) err = "".join(errors) if isinstance(errors, list) else errors if type(errors) is str else repr(errors); + dialogs.warningMsgBox({'title' : _('Transaction with warnings',), 'text' : err.replace("\n", "
"), 'richtext' : True }) logger.warning("Transaction with warnings: %s", repr(errors)) - ok = result == 0 or result == 1 + ok = result == 0 # Avoid to die "or result == 1" TODO manage Warning if ok: self.started_transaction = { 'Install': {},