From 3e21dc729dd289354389b7c59e25419e570eb899 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?--=3DFurtiF=E2=84=A2=3D--?= Date: Mon, 4 Mar 2024 14:50:11 +0100 Subject: [PATCH] fix format string (translate mode) --- ecu.py | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-) diff --git a/ecu.py b/ecu.py index b53ded15..5097d86e 100644 --- a/ecu.py +++ b/ecu.py @@ -1731,16 +1731,20 @@ def check_ecu2(self, diagversion, supplier, soft, version, label, addr, protocol if label is not None: label.setText("Found %i ecu" % self.num_ecu_found) - line = "" + _("Found ECU") + " [%s] " + _("(not perfect match)") + " :" \ + text = _("Found ECU") + text1 = _("(not perfect match)") + line = f"{text} {ecu_type} {text1} :" \ "%s DIAGVERSION [%s] SUPPLIER [%s] SOFT [%s] VERSION [%s instead %s]" \ - % (ecu_type, kept_ecu.name, diagversion, supplier, soft, version, tgt.version) + % (kept_ecu.name, diagversion, supplier, soft, version, tgt.version) options.main_window.logview.append(line) if not found_exact and not found_approximate: - line = "" + _("Found ECU") + " [%s] " + _("(no relevant ECU file found)") + " :" \ + text = _("Found ECU") + text1 = _("(no relevant ECU file found)") + line = f"{text} {ecu_type} {text1} :" \ "DIAGVERSION [%s] SUPPLIER [%s] SOFT [%s] VERSION [%s]" \ - % (ecu_type, diagversion, supplier, soft, version) + % (diagversion, supplier, soft, version) options.main_window.logview.append(line)