The MCP v2 upgrade boots fine and quietly drops your instructions

Your MCP server starts after the upgrade and the agent stops following the rules you wrote into it. The constructor arguments moved one slot, and nothing raised an error.

Read in Indonesian

After running pip install -U mcp and restarting a server, the process boots, the logs look normal, and tool calls return answers. The agent still stops following the server instructions because that string no longer reaches the model. Nothing in the logs explains it because nothing raises.

Key takeaways

  • The Python SDK v2 rename fails loudly: FastMCP is MCPServer now, and the old import raises ModuleNotFoundError that names its own replacement.
  • The dangerous change is positional: instructions moved to the fourth constructor slot, so a v1 call puts your briefing in title and leaves instructions empty, with no error.
  • Transport options left the constructor, so MCPServer('x', port=9000) raises TypeError and the port belongs on run() instead.
  • The protocol moved to 2026-07-28 in the same release, so there is no handshake, no session, and no server-initiated request on a modern connection.
  • Pin mcp<2 if you are not migrating this week, because the v1 line is in maintenance and still receives security patches.

The errors that fail loudly

If your server imports FastMCP the old way, the upgrade stops you at the first line. Here is the exact message I measured on mcp 2.3.0.

Output
$ python3 -c "from mcp.server.fastmcp import FastMCP" 2>&1 | tail -1
ModuleNotFoundError: No module named 'mcp.server.fastmcp'. This is mcp 2.x, where FastMCP was renamed to MCPServer (from mcp.server.mcpserver import MCPServer) and other APIs changed; see the migration guide at https://py.sdk.modelcontextprotocol.io/v2/migration/#fastmcp-renamed-to-mcpserver or pin 'mcp<2' to keep running v1 code.

The message names its own fix: FastMCP is now MCPServer, and the text links the migration guide. It also offers a second exit, which is to pin mcp<2 and keep running v1 code. McpError fails the same way. Importing it from mcp.shared.exceptions raises ImportError, and the message names MCPError as the replacement.

The migration guide lists the changes almost every project hits. The rename is the first. Fields moving from camelCase to snake_case is the second, and it shows up as AttributeError: 'Tool' object has no attribute 'inputSchema'. Removed mcp.types names are the third, starting with ImportError: cannot import name 'Content' from 'mcp.types'. Each one stops the process at startup, so you catch it immediately.

The argument that changed meaning

The v1 constructor took name, then instructions, then website_url and icons. The v2 constructor takes name, title, description, instructions, website_url, icons and version. Two new slots now sit in front of instructions. If you passed it positionally, it landed in the wrong slot.

Both slots accept a str or None, so the call still runs. This is what I measured.

Output
$ python3 -c "from mcp.server import MCPServer; m=MCPServer('Demo','You answer questions about the weather.'); print(repr(m.title), m.instructions)"
'You answer questions about the weather.' None

The sentence sits in .title, and .instructions is None. I connected an in-process client to that server. It received serverInfo.title set to your sentence and instructions as None. The model gets a display name where it expected a briefing. Nothing raised, and your tests stay green unless one of them reads the instructions field.

The fix is one keyword: pass instructions= by name, as the corrected server in the last section does. The client then receives the string, and title is None.

Two defaults moved as well. A server built with no arguments reports the name mcp-server. And LATEST_PROTOCOL_VERSION now holds a different date.

Output
$ python3 -c "from mcp.server import MCPServer; from mcp.types import LATEST_PROTOCOL_VERSION as v; print(MCPServer().name, v)"
mcp-server 2026-07-28

The rest of the silent changes

Transport settings left the constructor. Host, port, stateless_http, json_response, endpoint paths and transport_security now go to run() and the app builders. Passing port to the constructor fails with a TypeError, so you catch it right away.

Output
$ python3 -c "from mcp.server import MCPServer; MCPServer('x', port=9000)" 2>&1 | tail -1
TypeError: MCPServer.__init__() got an unexpected keyword argument 'port'

mount_path is gone too. Mounting the ASGI app is the supported way to serve under a prefix.

An MCPError raised inside a tool now becomes a protocol error, and the model never sees it. Other exceptions surface as "Error executing tool". If you raised McpError to give the model a hint, that hint is gone.

A sync def handler now runs on a worker thread instead of the event loop, so reread any handler that assumed the loop's thread.

The Streamable HTTP lifespan runs once at startup instead of once per session. Anything you set up there is now shared across sessions.

The HTTP client is now httpx2. It validates TLS through truststore against the operating system trust store, not certifi's bundle. A minimal container with no system CA store starts failing the handshake.

The wire types moved to a separate mcp-types distribution. import mcp.types remains a permanent alias, so those imports keep working.

The protocol moved in the same revision

The SDK now implements the 2026-07-28 revision. The earlier dates are 2024-11-05, 2025-03-26, 2025-06-18 and 2025-11-25. In v1, LATEST_PROTOCOL_VERSION was 2025-11-25, the version the client offered during initialization. In v2 it is 2026-07-28, which the initialize handshake cannot negotiate. An in-process Client(server) on my box negotiated 2026-07-28 anyway.

At that revision a client does not open a connection, negotiate, then talk. Every request carries its protocol version, client info and client capabilities in _meta. server/discover is a plain request. Over Streamable HTTP there is no Mcp-Session-Id on the 2026 path, so anything keyed on that header sees nothing there.

Every server-initiated request is gone. On a 2026 connection, ctx.elicit() and ctx.session.create_message() fail with NoBackChannelError. They still work for legacy clients. The replacement returns the question from a tool, through a parameter annotated with Resolve(...).

One app serves both eras. The same app answers a 2025-era client's initialize and a 2026-era client's requests, with no flag to flip and no separate deployment. So a single test client proves little. An elicit call can pass against an old client and fail against a new one.

What to do this week

This is the corrected server. I ran it against the in-process client, and the instructions arrived as 'Answer with the article table schema before you search.' while title was None. The tool registered with a schema derived from the type hints. Calling it returned "Found 3 articles matching 'mcp'."

PYTHON
# server.py
from mcp.server import MCPServer

mcp = MCPServer(
    "Invasikode Database Server",
    instructions="Answer with the article table schema before you search.",
)


@mcp.tool()
def search_articles_by_keyword(keyword: str, limit: int = 5) -> str:
    """Search articles by a keyword in the title.

    Args:
        keyword: The search keyword.
        limit: Maximum number of articles returned.
    """
    return f"Found {limit} articles matching '{keyword}'."

If you are not migrating this week, pin mcp<2. The v1.x line is in maintenance, still gets critical bug fixes and security patches, and keeps its docs at /v1/. A library that depends on mcp should hold an upper bound such as mcp>=1.28,<2 until it has migrated.

If you are migrating, check the instructions argument first because passing it positionally fails without an error.

What I could not verify

I measured everything above on mcp 2.3.0 and Python 3.14.9 on one Linux box with an in-process client. I did not test a Streamable HTTP deployment, a multi-replica request_state setup, or the truststore handshake failure in a minimal container. The thread, lifespan, and httpx2 changes come from the SDK docs rather than local runs.

Check your MCPServer(...) constructor call and make sure instructions is passed by keyword.

Get better at shipping code.

Join the other developers getting tech updates, tips, and relaxed tutorials in their inbox every week.

Stay in the loop

Tech updates, coding tips, and relaxed insights straight to your inbox every week.

No spam. Unsubscribe anytime.

Read next

See all
Struktur DataWhat a Linked List Actually Is

A linked list is a linear chain of nodes, each holding data and a pointer to the next node. Here is what that chain looks like, what it costs next to an array, and the same minimal implementation in Java, Python, and JavaScript.

PascalPascal Capstone: Why Every Gradebook Score Came Back Zero

A gradebook reads three students from a file, prints three rows, and every score is 0. The procedure filled a copy of the array, because the parameter was missing var. Add the word and the report matches the file; the compiler had already warned about the call that filled nothing.

For developers who learn by struggling

© 2026 Inva.dev.