mirror of
https://github.com/BerriAI/litellm.git
synced 2026-10-08 03:08:45 +00:00
test fixes
This commit is contained in:
parent
0b1a9f6623
commit
62d3cab965
2 changed files with 5 additions and 2 deletions
|
|
@ -385,6 +385,9 @@ class _OPTIONAL_PresidioPIIMasking(CustomGuardrail):
|
|||
)
|
||||
continue
|
||||
return final_results
|
||||
except GuardrailRaisedException:
|
||||
# Re-raise GuardrailRaisedException without wrapping
|
||||
raise
|
||||
except Exception as e:
|
||||
# Sanitize exception to avoid leaking the original text (which may
|
||||
# contain API keys or other secrets) in error responses.
|
||||
|
|
|
|||
|
|
@ -1,4 +1,4 @@
|
|||
from typing import Any, Dict, Optional, Union, TYPE_CHECKING
|
||||
from typing import TYPE_CHECKING, Any, Dict, Optional, Union
|
||||
|
||||
from litellm._logging import verbose_proxy_logger
|
||||
from litellm.caching import DualCache
|
||||
|
|
@ -402,7 +402,7 @@ def _update_metadata_fields(updated_kv: dict) -> None:
|
|||
updated_kv: The key-value dict being used for the update
|
||||
"""
|
||||
for field in LiteLLM_ManagementEndpoint_MetadataFields_Premium:
|
||||
if field in updated_kv and _has_non_empty_value(updated_kv[field]):
|
||||
if field in updated_kv and updated_kv[field] is not None:
|
||||
_update_metadata_field(updated_kv=updated_kv, field_name=field)
|
||||
|
||||
for field in LiteLLM_ManagementEndpoint_MetadataFields:
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue