From d7f7f96cd43ab3ffd45f2fa1a24556cb94316b53 Mon Sep 17 00:00:00 2001 From: Berack96 Date: Wed, 29 Oct 2025 23:13:37 +0100 Subject: [PATCH] fix docstring missing + better exit if error --- src/app/__main__.py | 2 ++ src/app/configs.py | 3 +-- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/src/app/__main__.py b/src/app/__main__.py index 2e9559c..a97d2eb 100644 --- a/src/app/__main__.py +++ b/src/app/__main__.py @@ -1,5 +1,6 @@ import asyncio import logging +import sys from dotenv import load_dotenv from app.configs import AppConfig from app.interface import * @@ -34,3 +35,4 @@ if __name__ == "__main__": except Exception as e: logging.error(f"Application failed to start: {e}") + sys.exit(1) diff --git a/src/app/configs.py b/src/app/configs.py index 255f435..a93d582 100644 --- a/src/app/configs.py +++ b/src/app/configs.py @@ -154,8 +154,7 @@ class AgentsConfigs(BaseModel): Validate that the default models and strategy exist in the provided configurations. If any default is not found, a ValueError is raised. Args: - models: ModelsConfig instance containing all available models. - strategies: list of Strategy instances containing all available strategies. + configs: the AppConfig instance containing models and strategies. Raises: ValueError if any default model or strategy is not found. """