Repository navigation
fix(cursor): ask_user works again with the out-of-process Cursor SDK - #78
Merged
Merged
Conversation
Cursor now runs in a worker process, and send options reach it as JSON. The ask_user tool's execute function was dropped on the way, so every call failed with "i.execute is not a function". The worker now gives each custom tool an execute that sends a customToolCall frame to the server. The server runs the real tool and replies with customToolResult. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Custom tools passed when opening a Cursor agent would reach the worker without execute, the same silent failure as ask_user. The process runner now refuses them with a clear error. A tool call that arrives after its run has finished now says the run ended instead of calling the tool unknown. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Cursor's
ask_userquestion tool failed on every call in 0.1.66 withi.execute is not a function. Upstream pingdotgg#39526 moved the Cursor SDK into a worker process, and send options now reach it as JSON, so the tool'sexecutefunction was dropped on the way.ask_useris Ctrl-only, so upstream's worker protocol had no way to call back into the server.Fix
executethat sends acustomToolCallframe to the server and waits.customToolResult.openare refused with a clear error, so the same silent failure can't come back that way.Testing
vp run check:changed: format, lint, knip and tests pass. Typecheck fails only inevalsmcp-tool-use/run.ts, which this PR doesn't touch.Claude Opus 5.5 in Claude Code.
🤖 Generated with Claude Code