From e7f0b02e438934d9cf0c4147cea8324d558bab8d Mon Sep 17 00:00:00 2001 From: Stefano Pigozzi Date: Sun, 26 Jul 2020 18:39:43 +0200 Subject: [PATCH] Use relative imports --- royalnet/serf/serf.py | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/royalnet/serf/serf.py b/royalnet/serf/serf.py index 628e0ca8..c9642643 100644 --- a/royalnet/serf/serf.py +++ b/royalnet/serf/serf.py @@ -41,10 +41,10 @@ class Serf(abc.ABC): log.debug(f"Importing pack: {pack_name}") try: packs[pack_name] = { - "commands": importlib.import_module(f"{pack_name}.commands"), - "events": importlib.import_module(f"{pack_name}.events"), - "stars": importlib.import_module(f"{pack_name}.stars"), - "tables": importlib.import_module(f"{pack_name}.tables"), + "commands": importlib.import_module(f".commands", pack_name), + "events": importlib.import_module(f".events", pack_name), + "stars": importlib.import_module(f".stars", pack_name), + "tables": importlib.import_module(f".tables", pack_name), } except ImportError as e: log.error(f"{e.__class__.__name__} during the import of {pack_name}:\n"