diff --git a/wlauto/core/bootstrap.py b/wlauto/core/bootstrap.py index cfca78bf..540522a4 100644 --- a/wlauto/core/bootstrap.py +++ b/wlauto/core/bootstrap.py @@ -169,7 +169,9 @@ def init_environment(env_root, dep_dir, extension_paths, overwrite_existing=Fals _env_root = os.getenv('WA_USER_DIRECTORY', os.path.join(_user_home, '.workload_automation')) _dep_dir = os.path.join(_env_root, 'dependencies') _extension_paths = [os.path.join(_env_root, ext.default_path) for ext in _extensions] -_extension_paths.extend(os.getenv('WA_EXTENSION_PATHS', '').split(os.pathsep)) +_env_var_paths = os.getenv('WA_EXTENSION_PATHS', '') +if _env_var_paths: + _extension_paths.extend(_env_var_paths.split(os.pathsep)) if not os.path.isdir(_env_root): init_environment(_env_root, _dep_dir, _extension_paths)