MCPcopy Create free account
hub / github.com/ChromeDevTools/chrome-devtools-mcp / formatValidationError

Function formatValidationError

src/ToolHandler.ts:232–240  ·  view source on GitHub ↗
(toolName: string, error: zod.ZodError)

Source from the content-addressed store, hash-verified

230}
231
232function formatValidationError(toolName: string, error: zod.ZodError): string {
233 const details = error.issues
234 .map(
235 issue =>
236 `${issue.path.length > 0 ? `${issue.path.join('.')}: ` : ''}${issue.message}`,
237 )
238 .join(', ');
239 return `Input validation error: Invalid arguments for tool ${toolName}: ${details}`;
240}
241
242function errorResult(text: string): CallToolResult {
243 return {

Callers 1

handleMethod · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected