Skip to content

Commit efcf193

Browse files
committed
Apply formatting fixes from ruff
1 parent c6473e7 commit efcf193

File tree

4 files changed

+11
-23
lines changed

4 files changed

+11
-23
lines changed

libraries/microsoft-agents-a365-tooling-extensions-azureaifoundry/microsoft_agents_a365/tooling/extensions/azureaifoundry/services/mcp_tool_registration_service.py

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -149,9 +149,7 @@ async def _get_mcp_tool_definitions_and_resources(
149149
return ([], None)
150150

151151
if len(servers) == 0:
152-
self._logger.info(
153-
f"No MCP servers configured for AgentUserId={agent_user_id}"
154-
)
152+
self._logger.info(f"No MCP servers configured for AgentUserId={agent_user_id}")
155153
return ([], None)
156154

157155
# Collections to build for the return value

libraries/microsoft-agents-a365-tooling-extensions-semantickernel/microsoft_agents_a365/tooling/extensions/semantickernel/services/mcp_tool_registration_service.py

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -171,9 +171,7 @@ async def add_tool_servers_to_agent(
171171
# Private Methods - Input Validation & Processing
172172
# ============================================================================
173173

174-
def _validate_inputs(
175-
self, kernel: Any, agent_user_id: str, auth_token: str
176-
) -> None:
174+
def _validate_inputs(self, kernel: Any, agent_user_id: str, auth_token: str) -> None:
177175
"""Validate all required inputs."""
178176
if kernel is None:
179177
raise ValueError("kernel cannot be None")

libraries/microsoft-agents-a365-tooling/microsoft_agents_a365/tooling/services/mcp_tool_server_configuration_service.py

Lines changed: 9 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -65,9 +65,7 @@ def __init__(self, logger: Optional[logging.Logger] = None):
6565
# PUBLIC API
6666
# --------------------------------------------------------------------------
6767

68-
async def list_tool_servers(
69-
self, agent_user_id: str, auth_token: str
70-
) -> List[MCPServerConfig]:
68+
async def list_tool_servers(self, agent_user_id: str, auth_token: str) -> List[MCPServerConfig]:
7169
"""
7270
Gets the list of MCP Servers that are configured for the agent.
7371
@@ -85,9 +83,7 @@ async def list_tool_servers(
8583
# Validate input parameters
8684
self._validate_input_parameters(agent_user_id, auth_token)
8785

88-
self._logger.info(
89-
f"Listing MCP tool servers for agent {agent_user_id}"
90-
)
86+
self._logger.info(f"Listing MCP tool servers for agent {agent_user_id}")
9187

9288
# Determine configuration source based on environment
9389
if self._is_development_scenario():
@@ -214,9 +210,7 @@ def _get_manifest_search_locations(self) -> List[Path]:
214210

215211
return search_locations
216212

217-
def _parse_manifest_file(
218-
self, manifest_path: Path
219-
) -> List[MCPServerConfig]:
213+
def _parse_manifest_file(self, manifest_path: Path) -> List[MCPServerConfig]:
220214
"""
221215
Parses the manifest file and extracts MCP server configurations.
222216
@@ -243,9 +237,7 @@ def _parse_manifest_file(
243237
print(f"📊 Processing {len(mcp_servers_data)} server entries")
244238
for server_element in mcp_servers_data:
245239
print(f"🔧 Processing server element: {server_element}")
246-
server_config = self._parse_manifest_server_config(
247-
server_element
248-
)
240+
server_config = self._parse_manifest_server_config(server_element)
249241
if server_config is not None:
250242
print(
251243
f"✅ Created server config: {server_config.mcp_server_name} -> {server_config.mcp_server_unique_name}"
@@ -329,7 +321,10 @@ async def _load_servers_from_gateway(
329321

330322
return mcp_servers
331323

332-
def _prepare_gateway_headers(self, auth_token: str,) -> Dict[str, str]:
324+
def _prepare_gateway_headers(
325+
self,
326+
auth_token: str,
327+
) -> Dict[str, str]:
333328
"""
334329
Prepares headers for tooling gateway requests.
335330
@@ -427,9 +422,7 @@ def _parse_gateway_server_config(
427422
# VALIDATION AND UTILITY HELPERS
428423
# --------------------------------------------------------------------------
429424

430-
def _validate_input_parameters(
431-
self, agent_user_id: str, auth_token: str
432-
) -> None:
425+
def _validate_input_parameters(self, agent_user_id: str, auth_token: str) -> None:
433426
"""
434427
Validates input parameters for the main API method.
435428

libraries/microsoft-agents-a365-tooling/microsoft_agents_a365/tooling/utils/utility.py

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -67,7 +67,6 @@ def build_mcp_server_url(server_name: str) -> str:
6767
return f"{base_url}/{server_name}"
6868

6969

70-
7170
def _get_current_environment() -> str:
7271
"""
7372
Gets the current environment name.

0 commit comments

Comments
 (0)