Close local release-quality gaps and reconcile workplan status
All checks were successful
CI Smoke / host-smoke (push) Successful in 1s
CI Smoke / container-smoke (push) Successful in 2s

Assistant: codex
Assistant-Model: gpt-6-astra
Assistant-Session: 01a0e332-3365-77c0-8491-084e9ea33ac1
This commit is contained in:
tegwick 2026-09-27 17:36:27 +02:00
parent 37436bb562
commit 7cd633986e
56 changed files with 462 additions and 237 deletions

View file

@ -2,7 +2,7 @@
LLM-specific exceptions.
"""
from typing import Optional, Dict, Any
from typing import Any
class LLMError(Exception):
@ -11,8 +11,8 @@ class LLMError(Exception):
def __init__(
self,
message: str,
cause: Optional[Exception] = None,
context: Optional[Dict[str, Any]] = None,
cause: Exception | None = None,
context: dict[str, Any] | None = None,
):
super().__init__(message)
self.cause = cause
@ -46,8 +46,8 @@ class LLMAPIError(LLMError):
message: str,
status_code: int = 0,
response_body: str = "",
cause: Optional[Exception] = None,
context: Optional[Dict[str, Any]] = None,
cause: Exception | None = None,
context: dict[str, Any] | None = None,
):
super().__init__(message, cause=cause, context=context)
self.status_code = status_code
@ -79,8 +79,8 @@ class LLMBudgetExceededError(LLMError):
total: int = 0,
spent: int = 0,
requested: int = 0,
cause: Optional[Exception] = None,
context: Optional[Dict[str, Any]] = None,
cause: Exception | None = None,
context: dict[str, Any] | None = None,
):
if context is None:
context = {"total": total, "spent": spent, "requested": requested}
@ -102,9 +102,9 @@ class LLMBalanceUnsupportedError(LLMConfigurationError):
self,
message: str,
provider: str = "",
supported: Optional[list[str]] = None,
cause: Optional[Exception] = None,
context: Optional[Dict[str, Any]] = None,
supported: list[str] | None = None,
cause: Exception | None = None,
context: dict[str, Any] | None = None,
):
supported_list = list(supported or [])
if context is None:
@ -127,8 +127,8 @@ class LLMSubprocessError(LLMError):
message: str,
return_code: int = 1,
stderr: str = "",
cause: Optional[Exception] = None,
context: Optional[Dict[str, Any]] = None,
cause: Exception | None = None,
context: dict[str, Any] | None = None,
):
super().__init__(message, cause=cause, context=context)
self.return_code = return_code