mirror of
https://github.com/BerriAI/litellm.git
synced 2026-11-12 08:42:18 +00:00
fix(mcp): satisfy type discipline gate
This commit is contained in:
parent
f82e588a50
commit
7421705c09
2 changed files with 5 additions and 3 deletions
|
|
@ -774,7 +774,7 @@ def _without_authorization(
|
|||
|
||||
|
||||
def _is_gateway_attribution_header(header_name: str) -> bool:
|
||||
return header_name.lower() in {"x-litellm-tags", "x-litellm-end-user-id"}
|
||||
return header_name.lower() in frozenset(("x-litellm-tags", "x-litellm-end-user-id"))
|
||||
|
||||
|
||||
def _format_byok_openapi_auth_header(mcp_server: MCPServer, mcp_auth_header: str) -> str:
|
||||
|
|
|
|||
|
|
@ -788,8 +788,10 @@ if MCP_AVAILABLE:
|
|||
|
||||
request_tags: Final = LiteLLMProxyRequestSetup.add_request_tag_to_metadata(
|
||||
llm_router=None,
|
||||
headers={key.lower(): value for key, value in (raw_headers or {}).items()},
|
||||
data={},
|
||||
headers={ # mutable-ok: request-tag helper accepts a mutable header mapping
|
||||
key.lower(): value for key, value in (raw_headers or {}).items()
|
||||
},
|
||||
data={}, # mutable-ok: request-tag helper mutates request metadata in place
|
||||
)
|
||||
listing: Final = await _list_mcp_tools(
|
||||
user_api_key_auth=user_api_key_auth,
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue