chore(lighthouse): change wording in new MCP Server class

This commit is contained in:
Rubén De la Torre Vico
2026-08-13 15:41:52 +02:00
parent 975c3f082d
commit cbc5f58998
+2 -7
View File
@@ -10,15 +10,10 @@ from prowler_mcp_server.lib.errors import tool_errors
class ProwlerMCP(FastMCP):
"""A FastMCP server whose tools all report failures the same way.
`FastMCP.tool()` is the single funnel every registration goes through -- the
`FastMCP.tool()` is the single funnel every registration goes through, the
`@server.tool()` and bare `@server.tool` decorator forms, and the direct
`mcp.tool(fn)` call `BaseTool` uses to auto-register -- so applying
`mcp.tool(fn)` call `BaseTool` uses to auto-register, so applying
`tool_errors` here covers all of them at once.
It is applied here rather than by hand because forgetting it is silent and
expensive: every server sets `mask_error_details=True`, so an unwrapped tool
answers `Error calling tool 'x'` and nothing else. Nothing about the tool looks
wrong, and the schema, the name and the description are all still correct.
"""
def tool(self, name_or_fn: Any = None, **kwargs: Any) -> Any: