You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Migrate MCP server from fastapi_mcp to MCP Python SDK #6252
fastapi_mcp crashes with RecursionError on any self-referencing Pydantic model in the OpenAPI schema (no cycle detection in resolve_schema_references()). This is app-wide — one recursive route kills the entire MCP server. It also generates LLM-unfriendly schemas ($ref/$defs) and HTTP-derived tool names (post_get_online_features).
Solution
Replace fastapi_mcp with the MCP Python SDK (FastMCP). Define tools explicitly via @mcp.tool(), calling FeatureStore methods directly (no internal HTTP round-trip).
Benefits
Unblocks recursive Pydantic models (compound filters, nested types) on HTTP routes without breaking MCP
Flat, LLM-friendly tool schemas (no $ref/$defs)
Semantic tool names (get_online_features, not post_get_online_features)
New registry discovery tools (list_feature_views, list_entities, list_feature_services, list_data_sources)
No HTTP noise (health checks, static files, WebSocket routes not exposed)
Direct FeatureStore calls instead of internal HTTP round-trip
@ihmdika I think @patelchaitany is working on it, but it's worth checking if that limitation can be fixed within fastapi_mcp itself. If you can help with it, it would be great.
Activity
ihmdika commentedon Apr 10, 2026
Hey! I would like to take this on if it’s still available.
ntkathole commentedon Apr 10, 2026
@ihmdika I think @patelchaitany is working on it, but it's worth checking if that limitation can be fixed within fastapi_mcp itself. If you can help with it, it would be great.