index : archinstall32 | |
Archlinux32 installer | gitolite user |
summaryrefslogtreecommitdiff |
-rw-r--r-- | archinstall/lib/profiles.py | 5 |
diff --git a/archinstall/lib/profiles.py b/archinstall/lib/profiles.py index 45d82531..f63fb96d 100644 --- a/archinstall/lib/profiles.py +++ b/archinstall/lib/profiles.py @@ -88,9 +88,10 @@ class Profile(): def load_instructions(self): if (absolute_path := self.path): if os.path.splitext(absolute_path)[1] == '.py': - spec = importlib.util.spec_from_file_location(absolute_path, absolute_path) + namespace = os.path.splitext(os.path.basename(absolute_path))[0] + spec = importlib.util.spec_from_file_location(namespace, absolute_path) imported = importlib.util.module_from_spec(spec) - sys.modules[os.path.basename(absolute_path)] = imported + sys.modules[namespace] = imported return Imported(spec, imported) else: raise ProfileError(f'Extension {os.path.splitext(absolute_path)[1]} is not a supported profile model. Only .py is supported.') |