Where does the bug appear (feature/product)?
Cursor IDE
Describe the Bug
When clicking the cancel button during MCP tool execution, Cursor does not send the required notifications/cancelled message to the MCP server, causing tools to continue running in the background.
Steps to Reproduce
- Create an MCP server with a long-running tool (e.g., an agent that takes 30+ seconds)
- Configure the MCP server in Cursor’s
mcp.json - Trigger the tool from Cursor chat
- Click the Cancel button in the Tool Execution UI
- Observe that the tool continues running on the server side
Expected Behavior
According to the MCP specification, when the user clicks cancel:
- Cursor should send a
notifications/cancellednotification:{ "jsonrpc": "2.0", "method": "notifications/cancelled", "params": { "requestId": "123", "reason": "User requested cancellation" } } - The MCP SDK automatically calls
abort()on the stored AbortController - The server receives the abort signal via
extra.signal - The tool stops processing and cleans up resources
Actual Behavior
- User clicks cancel button
- No notification is sent to the MCP server
- Tool continues running in background
- No cleanup occurs
- Resources remain allocated
Evidence from Server Logs
When running an MCP server with debug logging:
[Tool invoked] signal: present, already aborted: false
[Abort listener registered] for request ID abc-123
[User clicks cancel in Cursor]
(No abort event fires - execution continues until completion)
The extra.signal is provided by the MCP SDK, but since Cursor never sends the cancellation notification, the signal never gets aborted.
Technical Verification
I verified this is a Cursor client issue, not an MCP SDK issue:
- MCP TypeScript SDK correctly implements cancellation:
RequestHandlerExtra.signalis documented and provided to all tool handlers- SDK listens for
notifications/cancelledand automatically callsabort() - This is standard MCP protocol behavior
Related Reports
- GitHub Issue #3609: “The mcp service did not receive a signal when the session was manually terminated” - Multiple users have confirmed this issue
- Forum Post: “Cursor doesn’t cancel long-running MCP tool” - Same issue reported on Sept 19, 2024
Additional Notes
This appears to be a missing feature in Cursor’s MCP client implementation. The cancel button exists in the UI, but it doesn’t properly communicate the cancellation to the MCP server according to the protocol.
Workaround: None available. Tools must complete or timeout naturally.
Request: Please implement proper notifications/cancelled support so MCP tools can be stopped when users click the cancel button.
Operating System
MacOS
Current Cursor Version (Menu → About Cursor → Copy)
- Cursor Version: 1.7.54 (Universal)
- VSCode Version: 1.99.3
- Commit: 5c17eb2968a37f66bc6662f48d6356a100b67be0
- Date: 2025-10-21T19:07:38.476Z
- Electron: 34.5.8
- Platform: macOS (Darwin arm64 25.0.0)
- MCP SDK: @modelcontextprotocol/sdk@^1.20.1
Does this stop you from using Cursor
No - Cursor works, but with this issue