From 3faa864713b909d0d978fad490c15caf7cf002da Mon Sep 17 00:00:00 2001 From: Julio Quinteros Pro Date: Sun, 1 Mar 2026 17:54:20 -0300 Subject: [PATCH] Fix PLR0915 lint error in _completion_streaming_iterator Add `# noqa: PLR0915` suppression to match the async twin `_acompletion_streaming_iterator` which already carries the same suppression. The function's complexity is inherent (nested class, generator with fallback logic, cleanup code). Co-Authored-By: Claude Opus 4.6 --- litellm/router.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/litellm/router.py b/litellm/router.py index 34408e38e40..f21718a34c3 100644 --- a/litellm/router.py +++ b/litellm/router.py @@ -1718,7 +1718,7 @@ class Router: return FallbackStreamWrapper(stream_with_fallbacks()) - def _completion_streaming_iterator( + def _completion_streaming_iterator( # noqa: PLR0915 self, model_response: CustomStreamWrapper, messages: List[Dict[str, str]],