Skip to content

Implementation of Tool-Level Error Mapping #34

Description

@gkorland

Description: Tool handlers currently throw raw exceptions or return unsanitized error strings that may include stack traces or internal connection details.

Impact: Leaking of internal implementation details and poor developer experience for LLM integrations.

Recommended Fix: Create a mapping utility (toMcpErrorResult) that scrubs sensitive data and returns consistent, user-safe error messages to the client.

Affected Files: src/mcp/tools.ts, src/errors/ErrorHandler.ts.

Metadata

Metadata

Labels

No labels
No labels

Type

No type

Fields

No fields configured for issues without a type.

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions