Refactoring code for modular approach

This commit is contained in:
2025-09-09 23:03:08 +02:00
parent 8fbe64687a
commit 1fc8810242
11 changed files with 74 additions and 84 deletions

View File

@@ -9,12 +9,12 @@ def setup_logging():
"""Configure application logging with file and console handlers"""
# Create logs directory if it doesn't exist
log_file = Path(settings.LOG_FILE)
log_file = Path(settings.log_file)
log_file.parent.mkdir(parents=True, exist_ok=True)
# Configure root logger
logger = logging.getLogger()
logger.setLevel(getattr(logging, settings.LOG_LEVEL.upper()))
logger.setLevel(getattr(logging, settings.log_level.upper()))
# Remove existing handlers
for handler in logger.handlers[:]: