style(lint): annotate Final bindings (LIT010) and remove extra provider rebind (LIT011)

This commit is contained in:
pfolex 2026-10-28 12:17:14 -04:00
parent 35da226610
commit c9b1a9772f
2 changed files with 2 additions and 4 deletions

View file

@ -1763,8 +1763,6 @@ def completion_cost(
)
)
region_name = hidden_params.get("region_name", region_name)
elif candidate_pricing_provider or candidate_custom_llm_provider:
custom_llm_provider = candidate_pricing_provider or candidate_custom_llm_provider
else:
if model is None:

View file

@ -150,14 +150,14 @@ class OpenAILikeChatConfig(OpenAIGPTConfig):
api_key: str | None = None,
json_mode: bool | None = None,
) -> ModelResponse:
resolved_custom_llm_provider = (
resolved_custom_llm_provider: Final = (
litellm_params.get("custom_llm_provider") if isinstance(litellm_params, dict) else None
) or (
model_response._hidden_params.get("custom_llm_provider")
if isinstance(model_response._hidden_params, dict)
else None
)
transformed_response = OpenAILikeChatConfig._transform_response(
transformed_response: Final = OpenAILikeChatConfig._transform_response(
model=model,
response=raw_response,
model_response=model_response,