A Model Context Protocol (MCP) server for executing Python code and managing Python packages.
{
"mcpServers": {
"mcp-python-executor": {
"env": {
"LOG_LEVEL": "info",
"LOG_FORMAT": "json",
"MAX_MEMORY_MB": "512",
"EXECUTION_TIMEOUT_MS": "30000",
"PREINSTALLED_PACKAGES": "numpy pandas matplotlib scikit-learn",
"MAX_CONCURRENT_EXECUTIONS": "5"
},
"args": [
"path/to/python-executor/build/index.js"
],
"command": "node"
}
}
}Are you the author?
Add this badge to your README to show your security score and help users find safe servers.
A Model Context Protocol (MCP) server for executing Python code and managing Python packages.
Is it safe?
No package registry to scan.
No authentication — any process on your machine can connect.
MIT. View license →
Is it maintained?
Last commit 407 days ago. 2 stars.
Will it work with my client?
Transport: stdio. Works with Claude Desktop, Cursor, Claude Code, and most MCP clients.
No automated test available for this server. Check the GitHub README for setup instructions.
No known vulnerabilities.
Have you used this server?
Share your experience — it helps other developers decide.
Sign in to write a review.
Dynamic problem-solving through sequential thought chains
A Model Context Protocol server for searching and analyzing arXiv papers
An open-source AI agent that brings the power of Gemini directly into your terminal.
The official Python SDK for Model Context Protocol servers and clients
MCP Security Weekly
Get CVE alerts and security updates for Mcp Python Executor and similar servers.
Start a conversation
Ask a question, share a tip, or report an issue.
Sign in to join the discussion.
A Model Context Protocol (MCP) server for executing Python code and managing Python packages.
The server can be configured through environment variables in the MCP settings:
{
"mcpServers": {
"mcp-python-executor": {
"command": "node",
"args": ["path/to/python-executor/build/index.js"],
"env": {
"PREINSTALLED_PACKAGES": "numpy pandas matplotlib scikit-learn",
"MAX_MEMORY_MB": "512",
"EXECUTION_TIMEOUT_MS": "30000",
"MAX_CONCURRENT_EXECUTIONS": "5",
"LOG_LEVEL": "info",
"LOG_FORMAT": "json"
}
}
}
}
PREINSTALLED_PACKAGES: Space-separated list of Python packages to install on startupMAX_MEMORY_MB: Maximum memory limit per execution (default: 512)EXECUTION_TIMEOUT_MS: Maximum execution time in milliseconds (default: 30000)MAX_CONCURRENT_EXECUTIONS: Maximum number of concurrent executions (default: 5)LOG_LEVEL: Logging level (debug|info|error, default: info)LOG_FORMAT: Log format (json|text, default: json)Execute Python code and return the results.
interface ExecutePythonArgs {
code?: string; // Python code to execute (inline)
scriptPath?: string; // Path to existing Python script file (alternative to code)
inputData?: string[]; // Optional input data
}
Examples:
// Example with inline code
{
"code": "print('Hello, World!!')\nfor i in range(3): print(i)",
"inputData": ["optional", "input", "data"]
}
// Example with script path
{
"scriptPath": "/path/to/your_script.py",
"inputData": ["optional", "input", "data"]
}
Install Python packages.
interface InstallPackagesArgs {
packages: string[];
}
Example: