# Python Review

> Specialized auditor for FastAPI, FastMCP, and Python code security, async performance, and pytest coverage.

Python Review is a free AI agent skill on Agensi by Krimesh Shah, in Code Quality & Review. It loads into your AI agent through the Agensi MCP server, always in its latest approved version.

- Price: Free
- Creator: [Krimesh Shah](https://www.agensi.io/creators/krimesh-shah)
- Category: [Code Quality & Review](https://www.agensi.io/skills/code-quality-review)
- Version: 1.0
- Last updated: 2026-11-30
- Security: scan passed (2026-11-30); every new listing is also reviewed by a person
- Listing: https://www.agensi.io/skills/python-review
- Tags: code-review, python, fastapi, pytest, backend

## About this skill

Manual code reviews often miss subtle async bottlenecks or authorization gaps in FastAPI. This skill performs a deep inspection of Python source code, focusing on security, performance, and testing rigor.

### What it does
- **FastAPI validation** checks request/response models, middleware ordering, and identifies blocking I/O in async routes.
- **Security auditing** finds SQL injection, unsafe deserialization, shell invocations, and SSRF risks in user-provided URLs.
- **MCP tool review** treats FastMCP tools as privileged endpoints, validating arguments and resource constraints.
- **Logic analysis** detects mutable defaults, race conditions, and resource leaks in standard Python modules.
- **Test verification** evaluates pytest suites for boundary coverage, fixture isolation, and brittle mocks.

### How it works
1. Submit Python files or a directory of changed code for analysis.
2. The skill inspects the code along with relevant callers to understand data flow.
3. It cross-references implementation against FastAPI best practices and security patterns.
4. You receive a structured report detailing vulnerabilities, performance issues, and missing test cases.

### Frameworks & tools
This skill supports Python applications using FastAPI, FastMCP, and pytest. It addresses common risks in async/await patterns and Pydantic-based data validation.

### Why this beats prompting it yourself
Generic prompts often miss the specific nuances of FastAPI's dependency injection and async lifecycle. This skill enforces strict checks for tenant isolation and object-level authorization that standard linting tools overlook.

### Use cases
- Audit new FastAPI endpoints for authorization bypasses and PII leaks.
- Identify blocking synchronous calls inside async route handlers.
- Verify that pytest fixtures aren't leaking state between test runs.
- Review FastMCP tool implementations for potential path traversal or command injection.

### Known limitations
This skill focuses on code logic and structure. It cannot verify package vulnerabilities without external scanner output or confirm test results unless executed in an isolated environment.

## Requires

- Python

## How to use this skill

1. Connect your AI agent to Agensi once: add the MCP server https://mcp.agensi.io/mcp/auth and sign in with your Agensi account (OAuth, no API key). Steps for Claude, ChatGPT, Claude Code, Codex, Cursor, VS Code and other agents: https://www.agensi.io/docs/mcp-setup
2. Ask your agent: "Use the Python Review skill from Agensi" and describe your task.
3. Your agent loads the skill from Agensi when it needs it. Nothing is downloaded.

## Frequently asked questions

### What specific Python code issues does this skill identify?

This skill performs deep inspections of Python source code to find async bottlenecks, authorization gaps, and security risks like SQL injection or SSRF. It specifically looks for issues that standard linters miss, such as blocking I/O inside FastAPI routes and shared state in pytest fixtures.

### What do I need to provide to use this skill?

You only need to provide the Python files or the directory of changed code you want analyzed. Your AI agent uses this skill to cross reference your implementation against FastAPI best practices and security patterns without requiring additional software.

### What kind of report does this skill generate?

You receive a structured report detailing identified vulnerabilities, performance issues, and missing test cases. The analysis includes a review of data flow between the changed code and relevant callers to ensure a comprehensive evaluation.

### Can this skill review MCP tool implementations?

Yes, this skill treats FastMCP tools as privileged endpoints and validates all arguments and resource constraints. It checks for tenant boundaries, sensitive data leaks, and potential path traversal risks within your MCP tool implementations.

### Are there any types of security checks this skill does not perform?

This skill cannot verify package vulnerabilities without external scanner output or confirm actual test results unless executed in an isolated environment. It is focused on analyzing code logic, structure, and internal security patterns rather than external dependencies.

### How should I ask my AI agent to apply this skill to my project?

You can ask your AI agent to audit new FastAPI endpoints for authorization bypasses or to identify blocking synchronous calls in your async handlers. You can also request a review of your pytest suites to ensure fixtures are isolated and boundary cases are covered.

---

Source: [Agensi](https://www.agensi.io), the marketplace of skills for AI agents. Any MCP-compatible agent (Claude, ChatGPT, Claude Code, Codex, Cursor, VS Code and more) connects at https://mcp.agensi.io/mcp/auth and signs in with an Agensi account; setup for every agent: https://www.agensi.io/docs/mcp-setup. Append .md to any skill, guide or docs address on agensi.io for its markdown version.
