{
  "markdown": "# MCP Server Analyzer for Python 🐍🔍\n\n<!-- mcp-name: io.github.Anselmoo/mcp-server-analyzer -->\n\n[![SafeSkill 92/100](https://img.shields.io/badge/SafeSkill-92%2F100_Verified%20Safe-brightgreen)](https://safeskill.dev/scan/anselmoo-mcp-server-analyzer)\n\n[![CI/CD Pipeline](https://github.com/anselmoo/mcp-server-analyzer/actions/workflows/ci-cd.yml/badge.svg)](https://github.com/anselmoo/mcp-server-analyzer/actions/workflows/ci-cd.yml)\n[![PyPI version](https://badge.fury.io/py/mcp-server-analyzer.svg)](https://badge.fury.io/py/mcp-server-analyzer)\n[![Python 3.13+](https://img.shields.io/badge/python-3.13+-blue.svg)](https://www.python.org/downloads/)\n[![Docker](https://img.shields.io/badge/docker-available-blue.svg)](https://github.com/anselmoo/mcp-server-analyzer/pkgs/container/mcp-server-analyzer)\n[![License: MIT](https://img.shields.io/badge/License-MIT-yellow.svg)](https://opensource.org/licenses/MIT)\n[![Code Coverage](https://codecov.io/gh/anselmoo/mcp-server-analyzer/branch/main/graph/badge.svg)](https://codecov.io/gh/anselmoo/mcp-server-analyzer)\n[![AgentSeal MCP](https://agentseal.org/api/v1/mcp/mcp-server-analyzer/badge)](https://agentseal.org/mcp/mcp-server-analyzer)\n[![Docs](https://img.shields.io/badge/docs-GitHub%20Pages-blue)](https://anselmoo.github.io/mcp-server-analyzer/)\n\n\nA powerful [Model Context Protocol (MCP)](https://modelcontextprotocol.io/) server that provides comprehensive Python code analysis using [**Ruff**](https://docs.astral.sh/ruff/) for linting, [**ty**](https://docs.astral.sh/ty/) for type checking, and [**Vulture**](https://github.com/jendrikseipp/vulture) for dead code detection. Perfect for AI assistants, IDEs, and automated code review workflows.\n\n## 🚀 Quick Start\n\n### VS Code Integration (One-Click Install)\n\nFor quick installation, use one of the one-click install buttons below...\n\n[![Install with UV in VS Code](https://img.shields.io/badge/VS_Code-UV-0098FF?style=flat-square&logo=visualstudiocode&logoColor=white)](https://insiders.vscode.dev/redirect/mcp/install?name=analyzer&config=%7B%22command%22%3A%22uvx%22%2C%22args%22%3A%5B%22mcp-server-analyzer%22%5D%7D) [![Install with UV in VS Code Insiders](https://img.shields.io/badge/VS_Code_Insiders-UV-24bfa5?style=flat-square&logo=visualstudiocode&logoColor=white)](https://insiders.vscode.dev/redirect/mcp/install?name=analyzer&config=%7B%22command%22%3A%22uvx%22%2C%22args%22%3A%5B%22mcp-server-analyzer%22%5D%7D&quality=insiders)\n\n[![Install with Docker in VS Code](https://img.shields.io/badge/VS_Code-Docker-0098FF?style=flat-square&logo=visualstudiocode&logoColor=white)](https://insiders.vscode.dev/redirect/mcp/install?name=analyzer&config=%7B%22command%22%3A%22docker%22%2C%22args%22%3A%5B%22run%22%2C%22-i%22%2C%22--rm%22%2C%22ghcr.io%2Fanselmoo%2Fmcp-server-analyzer%22%5D%7D) [![Install with Docker in VS Code Insiders](https://img.shields.io/badge/VS_Code_Insiders-Docker-24bfa5?style=flat-square&logo=visualstudiocode&logoColor=white)](https://insiders.vscode.dev/redirect/mcp/install?name=analyzer&config=%7B%22command%22%3A%22docker%22%2C%22args%22%3A%5B%22run%22%2C%22-i%22%2C%22--rm%22%2C%22ghcr.io%2Fanselmoo%2Fmcp-server-analyzer%22%5D%7D&quality=insiders)\n\nFor manual installation, add the following JSON block to your User Settings (JSON) file in VS Code. You can do this by pressing `Ctrl + Shift + P` and typing `Preferences: Open User Settings (JSON)`.\n\nOptionally, you can add it to a file called `.vscode/mcp.json` in your workspace. This will allow you to share the configuration with others.\n\n> Note that the `mcp` key is needed when using the `mcp.json` file.\n\n**Using uvx (recommended):**\n\n```json\n{\n  \"mcp\": {\n    \"servers\": {\n      \"analyzer\": {\n        \"command\": \"uvx\",\n        \"args\": [\"mcp-server-analyzer\"]\n      }\n    }\n  }\n}\n```\n\n**Using Docker:**\n\n```json\n{\n  \"mcp\": {\n    \"servers\": {\n      \"analyzer\": {\n        \"command\": \"docker\",\n        \"args\": [\"run\", \"-i\", \"--rm\", \"ghcr.io/anselmoo/mcp-server-analyzer\"]\n      }\n    }\n  }\n}\n```\n\n### Universal Installation\n\n```bash\n# Install with uvx (recommended)\nuvx install mcp-server-analyzer\n\n# Install with pip\npip install mcp-server-analyzer\n\n# Run with Docker\ndocker run ghcr.io/anselmoo/mcp-server-analyzer:latest\n\n# Install from source\ngit clone https://github.com/anselmoo/mcp-server-analyzer.git\ncd mcp-server-analyzer\nuv sync --dev\nuv run mcp-server-analyzer\n```\n\n## 📋 Features\n\n- **🔍 RUFF Analysis**: Comprehensive Python linting with auto-fixes\n- **🧠 ty Type Checking**: Fast Python type analysis with rule-based diagnostics\n- **🧹 Dead Code Detection**: Find unused imports, functions, and variables with VULTURE\n- **⚡ Biome JS/TS Analysis**: Fast linting and formatting for JavaScript and TypeScript\n- **📊 Quality Scoring**: Combined analysis with quality metrics\n- **🚀 FastMCP Framework**: High-performance MCP server implementation\n- **🐳 Docker Ready**: Multi-architecture containers with security signing\n- **🔒 Secure**: All releases signed with Sigstore for supply chain security\n\n## 📈 Analysis Examples\n\n### RUFF Linting Preview\n\nSee comprehensive linting analysis examples: **[📋 RUFF Analysis Preview](examples/preview-ruff.md)**\n\n### VULTURE Dead Code Detection Preview\n\nExplore dead code detection capabilities: **[🧹 VULTURE Analysis Preview](examples/preview-vulture.md)**\n\n## 🛠️ Available Tools\n\n| Tool            | Description                           | Use Case                             |\n| --------------- | ------------------------------------- | ------------------------------------ |\n| `ruff-check`    | Lint Python code with RUFF            | Style violations, potential errors   |\n| `ruff-format`   | Format Python code with RUFF          | Code formatting and consistency      |\n| `ruff-check-ci` | CI/CD optimized RUFF output           | GitHub Actions, GitLab CI            |\n| `ty-check`      | Type-check Python code with ty        | Type safety, incorrect return values |\n| `vulture-scan`  | Dead code detection                   | Unused imports, functions, variables |\n| `biome-check`   | Lint JS/TS code with Biome            | Style violations, potential errors   |\n| `biome-format`  | Format JS/TS code with Biome          | Code formatting and consistency      |\n| `analyze-code`  | Combined Ruff + ty + Vulture analysis | Complete code quality assessment     |\n\n## 🔧 Configuration\n\n### Claude Desktop\n\nAdd to your `claude_desktop_config.json`:\n\n```json\n{\n  \"mcpServers\": {\n    \"analyzer\": {\n      \"command\": \"uvx\",\n      \"args\": [\"mcp-server-analyzer\"]\n    }\n  }\n}\n```\n\n### Zed\n\nAdd to your Zed settings.json:\n\n```json\n\"context_servers\": {\n  \"analyzer\": {\n    \"command\": \"uvx\",\n    \"args\": [\"mcp-server-analyzer\"]\n  }\n}\n```\n\n### Claude Code (project-level)\n\nPlace `.mcp.json` at your project root:\n\n```json\n{\n  \"mcpServers\": {\n    \"analyzer\": {\n      \"command\": \"uvx\",\n      \"args\": [\"mcp-server-analyzer\"]\n    }\n  }\n}\n```\n\n## 🧪 Development\n\n### Prerequisites\n\n- Python 3.13+\n- [uv](https://docs.astral.sh/uv/) (recommended) or pip\n- Node.js 22+ (for Biome JS/TS analysis)\n- [Docker](https://docker.com) (optional)\n\n### Setup\n\n```bash\n# Clone repository\ngit clone https://github.com/anselmoo/mcp-server-analyzer.git\ncd mcp-server-analyzer\n\n# Install Python dependencies\nuv sync --dev\n\n# Install Biome (JS/TS analyzer)\nnpm ci\n\n# Run tests\nuv run pytest\n\n# Run type checks\nuv run ty check src tests\n\n# Run pre-commit hooks\nuv tool run pre-commit run --all-files\n\n# Build Docker image\ndocker build -t mcp-server-analyzer .\n```\n\n### Testing\n\n```bash\n# Run all tests\nuv run pytest tests/ -v\n\n# Run with coverage\nuv run pytest --cov=src/mcp_server_analyzer --cov-report=html\n\n# Test specific functionality\nuv run pytest tests/test_server.py::TestAnalyzers::test_ruff_with_sample_code\n```\n\n## 📊 Quality Metrics\n\nThe server provides quality scoring based on:\n\n- **Ruff Issues**: Style violations, potential bugs, complexity metrics\n- **ty Diagnostics**: Static typing errors and warnings\n- **Dead Code Detection**: Unused imports, functions, variables\n- **Combined Score**: Weighted quality assessment (0-100)\n\n## 🔒 Security\n\n- **Signed Releases**: All releases signed with [Sigstore](https://sigstore.dev/)\n- **Container Signing**: Docker images signed with [Cosign](https://docs.sigstore.dev/cosign/overview/)\n- **Trusted Publishing**: PyPI releases use GitHub OIDC trusted publishing\n- **Vulnerability Scanning**: Automated security scanning in CI/CD\n- **Supply Chain Security**: SLSA Build Level 3 compliance\n- **Security Policy**: See [SECURITY.md](SECURITY.md) for vulnerability reporting\n\n## 🔍 Data Handling & Transparency\n\n- **In-memory only**: Code passed to tools is written to a temporary file, analyzed, and the file is deleted immediately — nothing is persisted between calls.\n- **No network calls**: The server makes no outbound network connections during analysis.\n- **No telemetry**: No usage data, analytics, or crash reports are collected.\n- **Subprocess isolation**: ruff, ty, and vulture are invoked with fixed argument lists — no shell expansion or arbitrary command execution.\n\n## 📚 Documentation\n\n- **[Full Documentation](https://anselmoo.github.io/mcp-server-analyzer/)** - GitHub Pages docs\n- **[Tools Reference](https://anselmoo.github.io/mcp-server-analyzer/tools/)** - Detailed tool parameters and return types\n- **[MCP Specification](https://modelcontextprotocol.io/)** - Learn about Model Context Protocol\n- **[FastMCP Framework](https://gofastmcp.com/)** - High-performance MCP implementation\n- **[Ruff Documentation](https://docs.astral.sh/ruff/)** - Python linter and formatter\n- **[ty Documentation](https://docs.astral.sh/ty/)** - Python type checker and language server\n- **[Vulture Documentation](https://github.com/jendrikseipp/vulture)** - Dead code finder\n\n## 🤝 Contributing\n\nContributions are welcome! Please see [CONTRIBUTING.md](CONTRIBUTING.md) for details.\n\n1. Fork the repository\n2. Create a feature branch (`git checkout -b feature/amazing-feature`)\n3. Commit your changes using [Conventional Commits](https://www.conventionalcommits.org/)\n4. Push to the branch (`git push origin feature/amazing-feature`)\n5. Open a Pull Request\n\n## 📝 License\n\nThis project is licensed under the MIT License - see the [LICENSE](LICENSE) file for details.\n\n## 🙏 Acknowledgments\n\n- [Astral](https://astral.sh/) for RUFF and uv\n- [Jendrik Seipp](https://github.com/jendrikseipp) for VULTURE\n- [Model Context Protocol](https://modelcontextprotocol.io/) team\n- [FastMCP](https://gofastmcp.com/) framework\n\n---\n\n**Made with ❤️ for better Python code quality**\n",
  "bytes": 10558,
  "sha": "b77c0a0437f64c2c9f9c0468f7a00d7713c6e7b8a2f86a28928b658b89e043a2",
  "repo_slug": "anselmoo/mcp-server-analyzer",
  "fonte": "repo",
  "truncated": false,
  "api": "https://agentalog.com/api/listings/mcp_io_github_anselmoo_mcp_server_analyzer_89a8a326/readme"
}