From 74baaaf1976b5d931a57ff0fc49f1e933ad184b9 Mon Sep 17 00:00:00 2001 From: Tin Chi Lo Date: Wed, 17 Jun 2026 16:30:40 -0700 Subject: [PATCH] refactor(mcp): rename upstream_credentials.py to resolver.py Avoids the outbound_credentials/upstream_credentials.py redundancy; the file holds the one resolve() entry point, so resolver.py names it for what it is. Renames the mapped test to test_resolver.py to match, and updates the test import and the types.py docstring pointer. Pure rename; UpstreamCredentialProvider keeps its name. --- .../{upstream_credentials.py => resolver.py} | 0 litellm/proxy/gateway/mcp/outbound_credentials/types.py | 2 +- .../gateway/{test_upstream_credentials.py => test_resolver.py} | 2 +- 3 files changed, 2 insertions(+), 2 deletions(-) rename litellm/proxy/gateway/mcp/outbound_credentials/{upstream_credentials.py => resolver.py} (100%) rename tests/mcp_tests/gateway/{test_upstream_credentials.py => test_resolver.py} (98%) diff --git a/litellm/proxy/gateway/mcp/outbound_credentials/upstream_credentials.py b/litellm/proxy/gateway/mcp/outbound_credentials/resolver.py similarity index 100% rename from litellm/proxy/gateway/mcp/outbound_credentials/upstream_credentials.py rename to litellm/proxy/gateway/mcp/outbound_credentials/resolver.py diff --git a/litellm/proxy/gateway/mcp/outbound_credentials/types.py b/litellm/proxy/gateway/mcp/outbound_credentials/types.py index b563d702693..dd9d23213b7 100644 --- a/litellm/proxy/gateway/mcp/outbound_credentials/types.py +++ b/litellm/proxy/gateway/mcp/outbound_credentials/types.py @@ -1,7 +1,7 @@ """The OAuth / upstream-credential vocabulary — the v2 typed seam. This module is the *contract* the credential build implements and the spec tests assert -against. It ships the data types only; the resolver lives in `upstream_credentials.py`. +against. It ships the data types only; the resolver lives in `resolver.py`. Design invariants encoded here: diff --git a/tests/mcp_tests/gateway/test_upstream_credentials.py b/tests/mcp_tests/gateway/test_resolver.py similarity index 98% rename from tests/mcp_tests/gateway/test_upstream_credentials.py rename to tests/mcp_tests/gateway/test_resolver.py index c4cb74796cc..aaa41276abb 100644 --- a/tests/mcp_tests/gateway/test_upstream_credentials.py +++ b/tests/mcp_tests/gateway/test_resolver.py @@ -26,7 +26,7 @@ from litellm.proxy.gateway.mcp.outbound_credentials.types import ( SharedKey, Subject, ) -from litellm.proxy.gateway.mcp.outbound_credentials.upstream_credentials import ( +from litellm.proxy.gateway.mcp.outbound_credentials.resolver import ( UpstreamCredentialProvider, ) from litellm.proxy.gateway.mcp.result import Error, Ok