-
Notifications
You must be signed in to change notification settings - Fork 81
Closed
Description
Description
The MCP-GSuite server crashes when it receives a notifications/cancelled
notification. This happens when a request times out (after approximately 10 seconds), and the client sends a cancellation notification that the server doesn't know how to handle.
Error from logs:
pydantic_core._pydantic_core.ValidationError: 5 validation errors for ClientNotification
ProgressNotification.method
Input should be 'notifications/progress' [type=literal_error, input_value='notifications/cancelled', input_type=str]
Root Cause
The MCP library version 1.1.0 doesn't properly support the notifications/cancelled
notification type, which is part of the MCP specification for request cancellation.
Solution
Upgrade to MCP library version 1.3.0 or later, which added support for request cancellation via notifications in PR modelcontextprotocol/python-sdk#167.
The PR specifically:
- Adds support for request cancellation via notifications
- Implements periodic cleanup of in-flight requests
- Tracks request state throughout the lifecycle
This should resolve the validation errors when the server receives cancellation notifications, especially in cases where operations time out.
Metadata
Metadata
Assignees
Labels
No labels