From 65388d877e255cfc919009279d8eac58f698d661 Mon Sep 17 00:00:00 2001 From: Julio Quinteros Pro Date: Fri, 20 Feb 2026 11:09:57 -0300 Subject: [PATCH] fix(policy_endpoints): explicitly re-export private helper functions from __init__.py `import *` does not re-export names starting with `_`, so the private competitor-enrichment helpers added in endpoints.py were invisible when imported from the package: from litellm.proxy.management_endpoints.policy_endpoints import ( _build_all_names_per_competitor, ... ) This caused an ImportError that prevented the entire test module from collecting. Add explicit imports for each private helper so they are accessible from the package namespace. Co-Authored-By: Claude Sonnet 4.6 --- .../management_endpoints/policy_endpoints/__init__.py | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/litellm/proxy/management_endpoints/policy_endpoints/__init__.py b/litellm/proxy/management_endpoints/policy_endpoints/__init__.py index 7f28c7b3b27..157d15c2710 100644 --- a/litellm/proxy/management_endpoints/policy_endpoints/__init__.py +++ b/litellm/proxy/management_endpoints/policy_endpoints/__init__.py @@ -8,3 +8,13 @@ are imported directly into this namespace. """ from litellm.proxy.management_endpoints.policy_endpoints.endpoints import * # noqa: F401, F403 +from litellm.proxy.management_endpoints.policy_endpoints.endpoints import ( # noqa: F401 + _build_all_names_per_competitor, + _build_comparison_blocked_words, + _build_competitor_guardrail_definitions, + _build_name_blocked_words, + _build_recommendation_blocked_words, + _build_refinement_prompt, + _clean_competitor_line, + _parse_variations_response, +)