""" Logging utilities for the application. """ from datetime import datetime, timezone from typing import Any def log_with_timestamp(message: Any, level: str = "INFO") -> None: """ Log a message with a timestamp. Args: message: The message to log (will be converted to string) level: Log level (default: INFO) """ current_time = datetime.now(timezone.utc).strftime("%Y-%m-%d %H:%M:%S %Z") print(f"[{current_time}] [{level}] {message}") def log_info(message: Any) -> None: """Log an info message with timestamp.""" log_with_timestamp(message, "INFO") def log_warning(message: Any) -> None: """Log a warning message with timestamp.""" log_with_timestamp(message, "WARNING") def log_error(message: Any) -> None: """Log an error message with timestamp.""" log_with_timestamp(message, "ERROR")