mirror of
https://github.com/open-webui/mcpo.git
synced 2026-11-05 01:27:39 +00:00
[GH-ISSUE #244] issue: $ref is creating bugs in integration with "mcpo" #109
Labels
No labels
bug
can't reproduce
documentation
enhancement
good first issue
help wanted
invalid
pull-request
question
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
open-webui/mcpo#109
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Originally created by @CatalinBinzari on GitHub (Sep 3, 2025).
Original GitHub issue: https://github.com/open-webui/mcpo/issues/244
Check Existing Issues
mcpo Version
latest
Open WebUI Version (if applicable)
No response
Operating System
wsl
Browser (if applicable)
No response
Confirmation
README.md.Expected Behavior
`$ uvx --python 3.12 mcpo --config ./mcpo.config.json --hot-reload --api-key "$MCPO_API_KEY"
Starting MCP OpenAPI Proxy with config file: ./mcpo.config.json
2025-09-03 17:40:54,726 - INFO - Starting MCPO Server...
2025-09-03 17:40:54,726 - INFO - Name: MCP OpenAPI Proxy
2025-09-03 17:40:54,726 - INFO - Version: 1.0
2025-09-03 17:40:54,726 - INFO - Description: Automatically generated API from MCP Tool Schemas
2025-09-03 17:40:54,726 - INFO - Hostname: WX-OR6416915
2025-09-03 17:40:54,726 - INFO - Port: 8000
2025-09-03 17:40:54,726 - INFO - API Key: Provided
2025-09-03 17:40:54,726 - INFO - CORS Allowed Origins: ['*']
2025-09-03 17:40:54,727 - INFO - Path Prefix: /
2025-09-03 17:40:54,727 - INFO - Loading MCP server configurations from: ./mcpo.config.json
2025-09-03 17:40:54,729 - INFO - Configuring MCP Servers:
2025-09-03 17:40:54,729 - INFO - Enabling hot reload for config file: ./mcpo.config.json
2025-09-03 17:40:54,734 - INFO - Started watching config file: /mnt/c/ecr/mcp/openwebui/mcpo.config.json
2025-09-03 17:40:54,734 - INFO - Uvicorn server starting...
INFO: Started server process [10504]
INFO: Waiting for application startup.
2025-09-03 17:40:54,744 - INFO - Initiating connection for server: 'gitlab'...
INFO [14:40:55.425] (1): Initializing server with transport mode:
WARN [14:40:55.426] (1): Starting GitLab MCP Server with stdio transport
2025-09-03 17:40:55,710 - ERROR - Failed to connect to MCP server 'better-gitlab-mcp-server': ExceptionGroup: unhandled errors in a TaskGroup (1 sub-exception)
Exception Group Traceback (most recent call last):
| File "/home/cb/.cache/uv/archive-v0/f9gCbKWpWVD5fmEokUM4J/lib/python3.12/site-packages/mcpo/main.py", line 422, in lifespan
| async with client_context as (reader, writer, *_):
| ^^^^^^^^^^^^^^
| File "/usr/lib/python3.12/contextlib.py", line 231, in aexit
| await self.gen.athrow(value)
| File "/home/cb/.cache/uv/archive-v0/f9gCbKWpWVD5fmEokUM4J/lib/python3.12/site-packages/mcp/client/stdio/init.py", line 181, in stdio_client
| anyio.create_task_group() as tg,
| ^^^^^^^^^^^^^^^^^^^^^^^^^
| File "/home/cb/.cache/uv/archive-v0/f9gCbKWpWVD5fmEokUM4J/lib/python3.12/site-packages/anyio/_backends/_asyncio.py", line 772, in aexit
| raise BaseExceptionGroup(
| ExceptionGroup: unhandled errors in a TaskGroup (1 sub-exception)
+-+---------------- 1 ----------------
| Exception Group Traceback (most recent call last):
| File "/home/cb/.cache/uv/archive-v0/f9gCbKWpWVD5fmEokUM4J/lib/python3.12/site-packages/mcp/client/stdio/init.py", line 187, in stdio_client
| yield read_stream, write_stream
| File "/home/cb/.cache/uv/archive-v0/f9gCbKWpWVD5fmEokUM4J/lib/python3.12/site-packages/mcpo/main.py", line 423, in lifespan
| async with ClientSession(reader, writer) as session:
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
| File "/home/cb/.cache/uv/archive-v0/f9gCbKWpWVD5fmEokUM4J/lib/python3.12/site-packages/mcp/shared/session.py", line 218, in aexit
| return await self._task_group.aexit(exc_type, exc_val, exc_tb)
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
| File "/home/cb/.cache/uv/archive-v0/f9gCbKWpWVD5fmEokUM4J/lib/python3.12/site-packages/anyio/_backends/_asyncio.py", line 772, in aexit
| raise BaseExceptionGroup(
| ExceptionGroup: unhandled errors in a TaskGroup (1 sub-exception)
+-+---------------- 1 ----------------
| Traceback (most recent call last):
| File "/home/cb/.cache/uv/archive-v0/f9gCbKWpWVD5fmEokUM4J/lib/python3.12/site-packages/mcpo/main.py", line 425, in lifespan
| await create_dynamic_endpoints(app, api_dependency=api_dependency)
| File "/home/cb/.cache/uv/archive-v0/f9gCbKWpWVD5fmEokUM4J/lib/python3.12/site-packages/mcpo/main.py", line 281, in create_dynamic_endpoints
| form_model_fields = get_model_fields(
| ^^^^^^^^^^^^^^^^^
| File "/home/cb/.cache/uv/archive-v0/f9gCbKWpWVD5fmEokUM4J/lib/python3.12/site-packages/mcpo/utils/main.py", line 242, in get_model_fields
| python_type_hint, pydantic_field_info = _process_schema_property(
| ^^^^^^^^^^^^^^^^^^^^^^^^^
| File "/home/cb/.cache/uv/archive-v0/f9gCbKWpWVD5fmEokUM4J/lib/python3.12/site-packages/mcpo/utils/main.py", line 131, in _process_schema_property
| type_hint, _ = _process_schema_property(
| ^^^^^^^^^^^^^^^^^^^^^^^^^
| File "/home/cb/.cache/uv/archive-v0/f9gCbKWpWVD5fmEokUM4J/lib/python3.12/site-packages/mcpo/utils/main.py", line 131, in _process_schema_property
| type_hint, _ = _process_schema_property(
| ^^^^^^^^^^^^^^^^^^^^^^^^^
| File "/home/cb/.cache/uv/archive-v0/f9gCbKWpWVD5fmEokUM4J/lib/python3.12/site-packages/mcpo/utils/main.py", line 117, in _process_schema_property
| assert ref in schema_defs, "Custom field not found"
| ^^^^^^^^^^^^^^^^^^
| AssertionError: Custom field not found
+------------------------------------
2025-09-03 17:40:55,713 - ERROR - Failed to establish connection for server: 'gitlab' - Multiple errors occurred:
2025-09-03 17:40:55,713 - ERROR - Error 1: ExceptionGroup: unhandled errors in a TaskGroup (1 sub-exception)
2025-09-03 17:40:55,713 - INFO -
--- Server Startup Summary ---
2025-09-03 17:40:55,713 - WARNING - Failed to connect to:
2025-09-03 17:40:55,713 - WARNING - - gitlab
2025-09-03 17:40:55,713 - INFO - --------------------------
2025-09-03 17:40:55,713 - ERROR - No MCP servers could be reached.
INFO: Application startup complete.
INFO: Uvicorn running on http://0.0.0.0:8000/ (Press CTRL+C to quit)
Actual Behavior
this helped to fix the issue, but I am limited to do not use next tools, however they are required
create_merge_request
list_commits
list_group_iterations
list_group_projects
list_issues
list_projects
merge_merge_request
update_issue
update_merge_request
cb@WX-OR6416915:/mnt/c/ecr/mcp/openwebui$ npx @modelcontextprotocol/inspector --cli \
npx -y @zereight/mcp-gitlab --method tools/list
| jq -r '.tools[] | select(.inputSchema|tostring|test("$ref")) | .name'
| sort -u
create_merge_request
list_commits
list_group_iterations
list_group_projects
list_issues
list_projects
merge_merge_request
update_issue
update_merge_request
cb@WX-OR6416915:/mnt/c/ecr/mcp/openwebui$ export GITLAB_DENIED_TOOLS_REGEX="$(
npx @modelcontextprotocol/inspector --cli
npx -y @zereight/mcp-gitlab --method tools/list
| jq -r '[.tools[] | select(.inputSchema|tostring|test("$ref")) | .name] | unique | join("|")'
)"
cb@WX-OR6416915:/mnt/c/ecr/mcp/openwebui$ uvx --python 3.12 mcpo@latest --config ./mcpo.config.json --hot-reload --api-key "$MCPO_API_KEY"
Installed 41 packages in 53ms
Starting MCP OpenAPI Proxy with config file: ./mcpo.config.json
2025-09-03 18:22:17,133 - INFO - Starting MCPO Server...
2025-09-03 18:22:17,133 - INFO - Name: MCP OpenAPI Proxy
2025-09-03 18:22:17,133 - INFO - Version: 1.0
2025-09-03 18:22:17,133 - INFO - Description: Automatically generated API from MCP Tool Schemas
2025-09-03 18:22:17,133 - INFO - Hostname: WX-OR6416915
2025-09-03 18:22:17,133 - INFO - Port: 8000
2025-09-03 18:22:17,133 - INFO - API Key: Provided
2025-09-03 18:22:17,134 - INFO - CORS Allowed Origins: ['*']
2025-09-03 18:22:17,134 - INFO - Path Prefix: /
2025-09-03 18:22:17,134 - INFO - Loading MCP server configurations from: ./mcpo.config.json
2025-09-03 18:22:17,137 - INFO - Configuring MCP Servers:
2025-09-03 18:22:17,137 - INFO - Enabling hot reload for config file: ./mcpo.config.json
2025-09-03 18:22:17,144 - INFO - Started watching config file: /mnt/c/ecr/mcp/openwebui/mcpo.config.json
2025-09-03 18:22:17,144 - INFO - Uvicorn server starting...
INFO: Started server process [19576]
INFO: Waiting for application startup.
2025-09-03 18:22:17,176 - INFO - Initiating connection for server: 'gitlab'...
2025-09-03 18:22:21,482 - INFO - Successfully connected to 'gitlab'.
2025-09-03 18:22:21,482 - INFO -
--- Server Startup Summary ---
2025-09-03 18:22:21,483 - INFO - Successfully connected to:
2025-09-03 18:22:21,483 - INFO - - gitlab
2025-09-03 18:22:21,483 - INFO - --------------------------
INFO: Application startup complete.
INFO: Uvicorn running on http://0.0.0.0:8000/ (Press CTRL+C to quit)
INFO [18:22:21.426] (19628): Initializing server with transport mode:
WARN [18:22:21.426] (19628): Starting GitLab MCP Server with stdio transport
Steps to Reproduce
mcpo.config:
{
"mcpServers": {
"gitlab-ro": {
"command": "npx",
"args": ["-y", "@zereight/mcp-gitlab"],
"env": {
"GITLAB_PERSONAL_ACCESS_TOKEN": "HIDDEN",
"GITLAB_API_URL": "http://127.0.0.1:80/api/v4",
"GITLAB_PROJECT_ID": "",
"GITLAB_ALLOWED_PROJECT_IDS": "",
"GITLAB_READ_ONLY_MODE": "false",
"USE_GITLAB_WIKI": "false",
"USE_MILESTONE": "false",
"USE_PIPELINE": "false",
"HTTP_PROXY": "",
"HTTPS_PROXY": "",
"NO_PROXY": "127.0.0.1,localhost,::1"
}
}
}
}
Logs & Screenshots
{
"mcpServers": {
"gitlab-ro": {
"command": "npx",
"args": ["-y", "@zereight/mcp-gitlab"],
"env": {
"GITLAB_PERSONAL_ACCESS_TOKEN": "glpat-sr6Jfc_LUWZ4x_3z7BsW",
"GITLAB_API_URL": "http://127.0.0.1:80/api/v4",
"GITLAB_PROJECT_ID": "",
"GITLAB_ALLOWED_PROJECT_IDS": "",
"GITLAB_READ_ONLY_MODE": "false",
"USE_GITLAB_WIKI": "false",
"USE_MILESTONE": "false",
"USE_PIPELINE": "false",
"HTTP_PROXY": "",
"HTTPS_PROXY": "",
"NO_PROXY": "127.0.0.1,localhost,::1"
}
}
}
}
Additional Information
No response
@vinnitu commented on GitHub (Sep 26, 2025):
as I understand this trouble still have a place?
@mpsa-ggabel commented on GitHub (Dec 3, 2025):
Hello,
Same issue with Cloudflare observability MCP server:
My config.json content:
@ManiFaridi commented on GitHub (Jan 9, 2026):
Hello,
I encountered the exact same issue with Softeria's MS365 MCP.