Skip to content

Commit

Permalink
convert ModuleLoadEnvironment to regular class instead of singleton
Browse files Browse the repository at this point in the history
  • Loading branch information
lexming committed Nov 6, 2024
1 parent 50b9195 commit b9a6c5a
Showing 1 changed file with 2 additions and 6 deletions.
8 changes: 2 additions & 6 deletions easybuild/tools/modules.py
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@
from easybuild.tools.build_log import EasyBuildError, EasyBuildExit, print_warning
from easybuild.tools.config import ERROR, IGNORE, PURGE, UNLOAD, UNSET
from easybuild.tools.config import EBROOT_ENV_VAR_ACTIONS, LOADED_MODULES_ACTIONS
from easybuild.tools.config import Singleton, build_option, get_modules_tool, install_path
from easybuild.tools.config import build_option, get_modules_tool, install_path
from easybuild.tools.config import SEARCH_PATH_BIN_DIRS, SEARCH_PATH_HEADER_DIRS, SEARCH_PATH_LIB_DIRS
from easybuild.tools.environment import ORIG_OS_ENVIRON, restore_env, setvar, unset_env_vars
from easybuild.tools.filetools import convert_name, mkdir, normalize_path, path_matches, read_file, which, write_file
Expand Down Expand Up @@ -169,11 +169,7 @@ def prepend(self, item):
self.paths.insert(0, item)


# singleton metaclass: only one instance is created
BaseModuleEnvironment = create_base_metaclass('BaseModuleEnvironment', Singleton, object)


class ModuleLoadEnvironment(BaseModuleEnvironment):
class ModuleLoadEnvironment:
"""Environment set by modules on load"""

def __init__(self):
Expand Down

0 comments on commit b9a6c5a

Please sign in to comment.