fix(runner): align SDK pin and complete real runtime verification (#2525)

* fix(runner): align SDK pin and workspace-aware integration fixtures

* fix(ci): format sources and resolve current migration head

* test(persistence): align standalone migration fixtures with current models

* test(web): align smoke fixtures with current processor UI

---------

Co-authored-by: dadachann <185672915+dadachann@users.noreply.github.com>
This commit is contained in:
Hyu
2026-09-11 12:57:29 +08:00
committed by GitHub
parent 24ddcfe13e
commit e631da0073
37 changed files with 485 additions and 219 deletions
+3 -11
View File
@@ -2327,15 +2327,9 @@ class MCPLoader(loader.ToolLoader):
return items
def _session_by_source_id(
self, context: TenantContext, source_id: str
) -> RuntimeMCPSession | None:
def _session_by_source_id(self, context: TenantContext, source_id: str) -> RuntimeMCPSession | None:
return next(
(
session
for session in self._sessions_for_context(context)
if session.server_uuid == source_id
),
(session for session in self._sessions_for_context(context) if session.server_uuid == source_id),
None,
)
@@ -2397,9 +2391,7 @@ class MCPLoader(loader.ToolLoader):
source_id: str | None = None,
) -> typing.Any:
"""执行工具调用"""
execution_context = await self._assert_execution_active(
_execution_context_from_query(query)
)
execution_context = await self._assert_execution_active(_execution_context_from_query(query))
if source_id is None and name == MCP_TOOL_LIST_RESOURCES:
if getattr(query, 'variables', {}).get('_pipeline_mcp_resource_agent_read_enabled', True) is not True:
raise ToolExecutionDeniedError(name, 'MCP resource agent reads are disabled')
+2 -6
View File
@@ -368,9 +368,7 @@ class ToolManager:
return None
return await self.plugin_tool_loader.get_tool(name, source_id=source_id)
if source == 'mcp':
return await self.mcp_tool_loader.get_tool(
context, name, source_id=source_id
)
return await self.mcp_tool_loader.get_tool(context, name, source_id=source_id)
return None
async def generate_tools_for_openai(self, use_funcs: list[resource_tool.LLMTool]) -> list:
@@ -488,9 +486,7 @@ class ToolManager:
if source_ref is not None:
execution_context = get_query_execution_context(query)
await self._bind_plugin_workspace(execution_context)
sandbox_available = await self._workspace_sandbox_available(
execution_context
)
sandbox_available = await self._workspace_sandbox_available(execution_context)
source = source_ref['source']
source_id = source_ref.get('source_id')
uses_source_id = False