Update protocol version handling

This commit is contained in:
Justin Spahr-Summers
2024-10-21 14:50:44 +01:00
parent 2d55eabb2f
commit eb1024c654
5 changed files with 15 additions and 11 deletions

View File

@@ -11,8 +11,8 @@ from mcp_python.shared.session import (
BaseSession,
RequestResponder,
)
from mcp_python.shared.version import SUPPORTED_PROTOCOL_VERSION
from mcp_python.types import (
LATEST_PROTOCOL_VERSION,
ClientNotification,
ClientRequest,
CreateMessageResult,
@@ -67,7 +67,7 @@ class ServerSession(
await responder.respond(
ServerResult(
InitializeResult(
protocolVersion=SUPPORTED_PROTOCOL_VERSION,
protocolVersion=LATEST_PROTOCOL_VERSION,
capabilities=self._init_options.capabilities,
serverInfo=Implementation(
name=self._init_options.server_name,