diff --git a/tests/test_postgresql.py b/tests/test_postgresql.py
index e9c0f19ab76f8dce1f012a2eb3f31066e4d9e7c0..7502efa9e5019c174b9f69799b0256fd05409de6 100755
--- a/tests/test_postgresql.py
+++ b/tests/test_postgresql.py
@@ -19,8 +19,8 @@ except ImportError:
 
 sys.path.append(str(Path(__file__).parents[1].resolve()))
 
-import utils as u
-from utils.apt import Apt
+import utils as u  # noqa: E402
+from utils.apt import Apt  # noqa: E402
 
 
 def is_ha(port: int) -> bool:
diff --git a/utils/__init__.py b/utils/__init__.py
index 8413191b83c9223dec12b2299cf4cc336fce88db..c9541b8cb89b627fbe1bf37cdc506fe62105fecf 100644
--- a/utils/__init__.py
+++ b/utils/__init__.py
@@ -180,7 +180,7 @@ def load_conf() -> dict:
     """
 
     conf = {}
-    base_dir = get_dir(__file__)
+    base_dir = str(Path(get_dir(__file__)).parent)
     files = (
         (str(Path(base_dir, DEFAULT_CONF_PATH)), True),
         (str(Path(base_dir, AUTO_CONF_PATH)), False),
diff --git a/utils/apt.py b/utils/apt.py
index d434c38b6132c3c8c02d8cdafc212efde475f04a..48cb8d09a054667365fcd8a10b9501e119af78b7 100644
--- a/utils/apt.py
+++ b/utils/apt.py
@@ -8,7 +8,6 @@ import utils as u
 
 try:
     import apt
-    import apt_pkg
 except ModuleNotFoundError:
     u.warning("apt python module not found")
     exit(2)
@@ -127,4 +126,3 @@ class Apt:
         upgradable_packages = [p for p in self.installed_packages if p.is_upgradable]
 
         return upgradable_packages
-