Add recursion depth to convert_anyof_null_to_nullable, constants.py. Fix recursive_detector.py raise error state

This commit is contained in:
Nicholas Grabar 2025-03-28 13:11:19 -07:00
parent 91564056a5
commit 36458f5eb5
7 changed files with 62 additions and 17 deletions

View file

@ -29,6 +29,7 @@ from litellm.types.utils import (
ModelResponseStream,
TextCompletionResponse,
)
from litellm.constants import DEFAULT_MAX_RECURSE_DEPTH
if TYPE_CHECKING:
from opentelemetry.trace import Span as _Span
@ -1522,7 +1523,7 @@ class ProxyConfig:
yaml.dump(new_config, config_file, default_flow_style=False)
def _check_for_os_environ_vars(
self, config: dict, depth: int = 0, max_depth: int = 10
self, config: dict, depth: int = 0, max_depth: int = DEFAULT_MAX_RECURSE_DEPTH
) -> dict:
"""
Check for os.environ/ variables in the config and replace them with the actual values.