From 49eb767a8615d87bfdb6f4163a1410101e9a1d6e Mon Sep 17 00:00:00 2001 From: Cursor Agent Date: Sat, 7 Mar 2026 04:39:33 +0000 Subject: [PATCH] fix: add @log_guardrail_information decorator to CrowdStrike AIDR guardrail The check_guardrail_apply_decorator.py CI check requires all guardrail apply_guardrail methods to have the @log_guardrail_information decorator. The CrowdStrike AIDR handler was missing it. Co-authored-by: Ishaan Jaff --- .../guardrail_hooks/crowdstrike_aidr/crowdstrike_aidr.py | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/litellm/proxy/guardrails/guardrail_hooks/crowdstrike_aidr/crowdstrike_aidr.py b/litellm/proxy/guardrails/guardrail_hooks/crowdstrike_aidr/crowdstrike_aidr.py index 9dea744c4e8..19c5d54213f 100644 --- a/litellm/proxy/guardrails/guardrail_hooks/crowdstrike_aidr/crowdstrike_aidr.py +++ b/litellm/proxy/guardrails/guardrail_hooks/crowdstrike_aidr/crowdstrike_aidr.py @@ -5,7 +5,10 @@ from typing_extensions import Any, override from fastapi import HTTPException from litellm._logging import verbose_proxy_logger -from litellm.integrations.custom_guardrail import CustomGuardrail +from litellm.integrations.custom_guardrail import ( + CustomGuardrail, + log_guardrail_information, +) from litellm.llms.custom_httpx.http_handler import ( get_async_httpx_client, httpxSpecialProvider, @@ -272,6 +275,7 @@ class CrowdStrikeAIDRHandler(CustomGuardrail): transformed_texts.append(texts[len(transformed_texts)]) return transformed_texts[: len(texts)] + @log_guardrail_information @override async def apply_guardrail( self,