mirror of
https://github.com/open-webui/open-webui.git
synced 2025-12-11 20:05:19 +00:00
enh: display mcp connection error
This commit is contained in:
parent
414ab51d5d
commit
03f207b803
1 changed files with 11 additions and 0 deletions
|
|
@ -1306,6 +1306,17 @@ async def process_chat_payload(request, form_data, user, metadata, model):
|
|||
}
|
||||
except Exception as e:
|
||||
log.debug(e)
|
||||
if event_emitter:
|
||||
await event_emitter(
|
||||
{
|
||||
"type": "chat:message:error",
|
||||
"data": {
|
||||
"error": {
|
||||
"content": f"Failed to connect to MCP server '{server_id}'"
|
||||
}
|
||||
},
|
||||
}
|
||||
)
|
||||
continue
|
||||
|
||||
tools_dict = await get_tools(
|
||||
|
|
|
|||
Loading…
Reference in a new issue