From 561a946f5b06b5801ef7f2ea1b8c8e66e30f5df0 Mon Sep 17 00:00:00 2001 From: CPD Date: Wed, 12 Mar 2025 16:44:35 +0100 Subject: [PATCH] Revert "Add logger" This reverts commit e071906d58d2143ebc7aced055a6ba20b4f31c6e. --- cpdctrl/utility/config_file.py | 6 ------ 1 file changed, 6 deletions(-) diff --git a/cpdctrl/utility/config_file.py b/cpdctrl/utility/config_file.py index 66c89ea..3291564 100644 --- a/cpdctrl/utility/config_file.py +++ b/cpdctrl/utility/config_file.py @@ -1,8 +1,6 @@ from os import environ, makedirs, path import yaml -import logging -log = logging.getLogger(__name__) class ConfigFile: """ Class managing a yaml config file. @@ -17,7 +15,6 @@ class ConfigFile: self.values = init_values self.filepath = filepath if path.isfile(self.filepath): - log.debug(f"[{self.filepath}] loading from file") with open(self.filepath, "r") as file: self.values |= yaml.safe_load(file) @@ -26,7 +23,6 @@ class ConfigFile: directory = path.dirname(self.filepath) if not path.isdir(directory): makedirs(directory) - log.debug(f"[{self.filepath}] saving to file") with open(self.filepath, "w") as file: yaml.dump(self.values, file) @@ -39,12 +35,10 @@ class ConfigFile: raise KeyError(f"Key '{name}' not found in config file '{self.filepath}'") def set(self, name: str, value): - log.debug(f"[{self.filepath}] set {name} = {value}") self.values[name] = value def get_values(self): return self.values.copy() def set_values(self, values): - log.debug(f"[{self.filepath}] set values = {values}") self.values = values \ No newline at end of file