MCP Server to run python code locally
Description:
A Python REPL environment server that executes code in persistent sessions
Category: Development Tools / Code Execution
Overview:
Installation & Configuration:
For MacOS:
~/Library/Application\ Support/Claude/claude_desktop_config.json
For Windows:
%APPDATA%/Claude/claude_desktop_config.json
Configuration JSON:
"python-local": {
"command": "path-to/python",
"args": ["path-to/python_local"],
"env": {
"PYTHON_PATH": "/usr/local/bin/python3"
}
}
Development Notes:
npx @modelcontextprotocol/inspector uv --directory /path/to/python_local run python-local
Key Features:
The server implements python_repl
tool requiring code
and session_id
arguments for execution.