MCP server for Python code analysis with RUFF linting and VULTURE dead code detection
SaferSkills independently audited mcp-server-analyzer (MCP Server) and scored it 100/100 (green). The audit ran 55 deterministic rules across Security, Supply Chain, Maintenance, Transparency, and Community; it found 0 high-severity and 0 lower-severity findings. The full rule-by-rule trace and per-finding evidence are below. Free, methodology-open.
Findings & checks · 0 flagged
Every scanned point with the score it earned and what moved between them.
First recorded scan — no prior version to compare against.
The primary manifest — the file an agent reads to learn what this artifact does.
A powerful Model Context Protocol (MCP) server that provides comprehensive Python code analysis using Ruff for linting, ty for type checking, and Vulture for dead code detection. Perfect for AI assistants, IDEs, and automated code review workflows.
For quick installation, use one of the one-click install buttons below...
For 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).
Optionally, you can add it to a file called .vscode/mcp.json in your workspace. This will allow you to share the configuration with others.
Note that themcpkey is needed when using themcp.jsonfile.
Using uvx (recommended):
{
"mcp": {
"servers": {
"analyzer": {
"command": "uvx",
"args": ["mcp-server-analyzer"]
}
}
}
}Using Docker:
{
"mcp": {
"servers": {
"analyzer": {
"command": "docker",
"args": ["run", "-i", "--rm", "ghcr.io/anselmoo/mcp-server-analyzer"]
}
}
}
}# Install with uvx (recommended)
uvx install mcp-server-analyzer
# Install with pip
pip install mcp-server-analyzer
# Run with Docker
docker run ghcr.io/anselmoo/mcp-server-analyzer:latest
# Install from source
git clone https://github.com/anselmoo/mcp-server-analyzer.git
cd mcp-server-analyzer
uv sync --dev
uv run mcp-server-analyzerSee comprehensive linting analysis examples: [📋 RUFF Analysis Preview](examples/preview-ruff.md)
Explore dead code detection capabilities: [🧹 VULTURE Analysis Preview](examples/preview-vulture.md)
| Tool | Description | Use Case |
|---|---|---|
ruff-check | Lint Python code with RUFF | Style violations, potential errors |
ruff-format | Format Python code with RUFF | Code formatting and consistency |
ruff-check-ci | CI/CD optimized RUFF output | GitHub Actions, GitLab CI |
ty-check | Type-check Python code with ty | Type safety, incorrect return values |
vulture-scan | Dead code detection | Unused imports, functions, variables |
analyze-code | Combined Ruff + ty + Vulture analysis | Complete code quality assessment |
Add to your claude_desktop_config.json:
{
"mcpServers": {
"analyzer": {
"command": "uvx",
"args": ["mcp-server-analyzer"]
}
}
}Add to your Zed settings.json:
"context_servers": {
"analyzer": {
"command": "uvx",
"args": ["mcp-server-analyzer"]
}
}Place .mcp.json at your project root:
{
"mcpServers": {
"analyzer": {
"command": "uvx",
"args": ["mcp-server-analyzer"]
}
}
}# Clone repository
git clone https://github.com/anselmoo/mcp-server-analyzer.git
cd mcp-server-analyzer
# Install dependencies
uv sync --dev
# Run tests
uv run pytest
# Run type checks
uv run ty check src tests
# Run pre-commit hooks
uv tool run pre-commit run --all-files
# Build Docker image
docker build -t mcp-server-analyzer .# Run all tests
uv run pytest tests/ -v
# Run with coverage
uv run pytest --cov=src/mcp_server_analyzer --cov-report=html
# Test specific functionality
uv run pytest tests/test_server.py::TestAnalyzers::test_ruff_with_sample_codeThe server provides quality scoring based on:
Contributions are welcome! Please see CONTRIBUTING.md for details.
git checkout -b feature/amazing-feature)git push origin feature/amazing-feature)This project is licensed under the MIT License - see the LICENSE file for details.
Made with ❤️ for better Python code quality
~30 seconds. Free. No account. Every finding cites a rule and a line of evidence.