Coverage for src / infra / mcp.py: 100%

7 statements  

« prev     ^ index     » next       coverage.py v7.13.0, created at 2026-01-04 04:43 +0000

1"""MCP server configuration for Claude Agent SDK. 

2 

3This module provides the single source of truth for MCP server configuration. 

4All MCP-related configuration should be imported from this module. 

5""" 

6 

7from __future__ import annotations 

8 

9from typing import TYPE_CHECKING, Any 

10 

11if TYPE_CHECKING: 

12 from pathlib import Path 

13 

14# Tools disabled for mala agents to reduce token waste 

15MALA_DISALLOWED_TOOLS: list[str] = ["TodoWrite"] 

16 

17 

18def get_mcp_servers( 

19 repo_path: Path, 

20) -> dict[str, Any]: 

21 """Get MCP servers configuration for agents. 

22 

23 Args: 

24 repo_path: Path to the repository. 

25 

26 Returns: 

27 Empty dictionary (no MCP servers configured). 

28 """ 

29 return {} 

30 

31 

32def get_disallowed_tools() -> list[str]: 

33 """Get list of disallowed tools. 

34 

35 Always includes MALA_DISALLOWED_TOOLS (tools disabled for mala agents). 

36 

37 Returns: 

38 List of tool names that should be disallowed. 

39 """ 

40 return list(MALA_DISALLOWED_TOOLS)