From 6dffb1e470b082b8ce4b473f2fc1b201300bcd15 Mon Sep 17 00:00:00 2001 From: "kuldeep.k@cisinlabs.com" Date: Mon, 23 Aug 2021 17:26:28 +0530 Subject: [PATCH] Added UISignalQueue.put at NoSectionError & NoOptionError exceptions & updated existing UISignalQueue.put msg --- src/class_singleWorker.py | 22 ++++++++++++++++++---- 1 file changed, 18 insertions(+), 4 deletions(-) diff --git a/src/class_singleWorker.py b/src/class_singleWorker.py index d7dad4f4..f302300d 100644 --- a/src/class_singleWorker.py +++ b/src/class_singleWorker.py @@ -560,6 +560,14 @@ class singleWorker(StoppableThread): self._getKeysForAddress(fromaddress) except (configparser.NoSectionError, configparser.NoOptionError) as err: self.logger.warning("Section or Option did not found: %s", err) + queues.UISignalQueue.put(( + 'updateSentItemStatusByAckdata', ( + ackdata, + tr._translate( + "MainWindow", + "Error! Could not find sender address" + " (your address) in the keys.dat file.")) + )) except Exception as err: self.logger.error( 'Error within sendBroadcast. Could not read' @@ -571,8 +579,7 @@ class singleWorker(StoppableThread): ackdata, tr._translate( "MainWindow", - "Error! Could not find sender address" - " (your address) in the keys.dat file.")) + "Error, can't send.")) )) continue @@ -1141,6 +1148,14 @@ class singleWorker(StoppableThread): fromaddress) except (configparser.NoSectionError, configparser.NoOptionError) as err: self.logger.warning("Section or Option did not found: %s", err) + queues.UISignalQueue.put(( + 'updateSentItemStatusByAckdata', ( + ackdata, + tr._translate( + "MainWindow", + "Error! Could not find sender address" + " (your address) in the keys.dat file.")) + )) except Exception as err: self.logger.error( 'Error within sendMsg. Could not read' @@ -1152,8 +1167,7 @@ class singleWorker(StoppableThread): ackdata, tr._translate( "MainWindow", - "Error! Could not find sender address" - " (your address) in the keys.dat file.")) + "Error, can't send.")) )) continue