File tree Expand file tree Collapse file tree 1 file changed +2
-16
lines changed Expand file tree Collapse file tree 1 file changed +2
-16
lines changed Original file line number Diff line number Diff line change @@ -66,28 +66,14 @@ local function handler(params)
66
66
error ({ code = - 32000 , message = " Internal server error" , data = " Failed to load diff module" })
67
67
end
68
68
69
- -- Use the new blocking diff operation
70
- local success , result = pcall (
71
- diff_module .open_diff_blocking ,
69
+ -- Call the blocking diff operation directly (no pcall to allow yielding)
70
+ local result = diff_module .open_diff_blocking (
72
71
params .old_file_path ,
73
72
params .new_file_path ,
74
73
params .new_file_contents ,
75
74
params .tab_name
76
75
)
77
76
78
- if not success then
79
- -- Check if this is already a structured error
80
- if type (result ) == " table" and result .code then
81
- error (result )
82
- else
83
- error ({
84
- code = - 32000 , -- Generic tool error
85
- message = " Error opening blocking diff" ,
86
- data = tostring (result ),
87
- })
88
- end
89
- end
90
-
91
77
-- result should already be MCP-compliant with content array format
92
78
return result
93
79
end
You can’t perform that action at this time.
0 commit comments