Skip to content

Commit cf325e4

Browse files
BUG: drop removed fastmcp experimental setting
1 parent 4b906d4 commit cf325e4

1 file changed

Lines changed: 2 additions & 3 deletions

File tree

src/mcp/server.py

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
from __future__ import annotations
44

55
from fastapi import FastAPI
6-
from fastmcp import FastMCP, settings
6+
from fastmcp import FastMCP
77

88

99
def build_mcp(app: FastAPI) -> FastMCP:
@@ -17,10 +17,9 @@ def build_mcp(app: FastAPI) -> FastMCP:
1717
FastMCP: The FastMCP instance corresponding to the provided FastAPI app.
1818
"""
1919

20-
if hasattr(app.state, 'mcp'):
20+
if hasattr(app.state, "mcp"):
2121
return app.state.mcp # type: ignore[attr-defined]
2222

23-
settings.experimental.enable_new_openapi_parser = True
2423
mcp = FastMCP.from_fastapi(app, name=app.title)
2524
app.state.mcp = mcp # type: ignore[attr-defined]
2625
return mcp

0 commit comments

Comments
 (0)