From c7ab0786ffe064ccaf57b46ec2d5783a214a5751 Mon Sep 17 00:00:00 2001 From: shrlnm Date: Sun, 16 Apr 2023 07:50:35 +0300 Subject: [PATCH] fix DTC interpretation visibility, fix in db_manager --- pyren3/mod_db_manager.py | 5 ++++- pyren3/mod_ecu_default.py | 4 ++-- 2 files changed, 6 insertions(+), 3 deletions(-) mode change 100755 => 100644 pyren3/mod_ecu_default.py diff --git a/pyren3/mod_db_manager.py b/pyren3/mod_db_manager.py index 9fba4d7..cb3c090 100644 --- a/pyren3/mod_db_manager.py +++ b/pyren3/mod_db_manager.py @@ -180,7 +180,10 @@ def file_in_clip( pattern ): return pattern in glob.glob(pattern) else: file_list = mod_globals.clip_arc.namelist() - return pattern in file_list + for l in file_list: + if pattern.lower() == l.lower(): + return l + return '' def extract_from_clip_to_cache( filename ): if mod_globals.clip_arc == '': diff --git a/pyren3/mod_ecu_default.py b/pyren3/mod_ecu_default.py old mode 100755 new mode 100644 index 52fb628..9274f78 --- a/pyren3/mod_ecu_default.py +++ b/pyren3/mod_ecu_default.py @@ -218,8 +218,8 @@ def get_default_std_b( df, mn, se, elm, calc, getDTCmnemo ): else: chr_val = '' # I'm no sure that it is right - if str(chr_val).encode("utf-8") in list(df[dtc].caracter.keys()): - interpretation = df[dtc].caracter[str(chr_val).encode("utf-8")] + if str(chr_val) in list(df[dtc].caracter.keys()): + interpretation = df[dtc].caracter[str(chr_val)] else: interpretation = ''