mirror of
https://github.com/BerriAI/litellm.git
synced 2026-10-16 04:29:31 +00:00
fix(presidio): restore setattr with noqa B010 to satisfy type checking
This commit is contained in:
parent
ac8ec7bb75
commit
da39634c16
1 changed files with 1 additions and 1 deletions
|
|
@ -1628,7 +1628,7 @@ class _OPTIONAL_PresidioPIIMasking(CustomGuardrail):
|
|||
if not getattr(assembled_model_response, "usage", None) and chunks:
|
||||
last_chunk_usage: Final = getattr(chunks[-1], "usage", None)
|
||||
if last_chunk_usage:
|
||||
assembled_model_response.usage = last_chunk_usage
|
||||
setattr(assembled_model_response, "usage", last_chunk_usage) # noqa: B010
|
||||
|
||||
def get_presidio_settings_from_request_data(self, data: dict) -> PresidioPerRequestConfig | None:
|
||||
if "metadata" in data:
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue