From 809f95ee1f1211888808e95b1755ff0ff3a07422 Mon Sep 17 00:00:00 2001 From: tazlin Date: Wed, 4 Oct 2023 10:52:26 -0400 Subject: [PATCH] fix: load env vars in download_models.py --- download_models.py | 13 +++++++------ 1 file changed, 7 insertions(+), 6 deletions(-) diff --git a/download_models.py b/download_models.py index 20c69fdd..b5b1154b 100644 --- a/download_models.py +++ b/download_models.py @@ -1,10 +1,5 @@ -import hordelib -from loguru import logger - -hordelib.initialise() - from horde_model_reference.model_reference_manager import ModelReferenceManager -from hordelib.shared_model_manager import SharedModelManager +from loguru import logger from horde_worker_regen.bridge_data.load_config import BridgeDataLoader, reGenBridgeData from horde_worker_regen.consts import BRIDGE_CONFIG_FILENAME @@ -25,10 +20,16 @@ def main() -> None: file_path=BRIDGE_CONFIG_FILENAME, horde_model_reference_manager=horde_model_reference_manager, ) + bridge_data.load_env_vars() except Exception as e: logger.error(e) input("Press any key to exit...") + import hordelib + + hordelib.initialise() + from hordelib.shared_model_manager import SharedModelManager + SharedModelManager.load_model_managers() if bridge_data.allow_controlnet: