1. Conduid
  2. Developer Tools
  3. Python Interpreter
MCP server · Developer Tools

Python Interpreter

MCP Python Interpreter: run python code. Python-mcp-server, mcp-python-server, Code Executor

71Good

Scored 8 hours ago · breakdown

About Python Interpreter

Python Interpreter is an MCP server published by yzfly in the Developer Tools category: mCP Python Interpreter: run python code. Python-mcp-server, mcp-python-server, Code Executor. Conduid read 10 tools from its source: clear_session, install_package, list_directory, list_installed_packages, list_python_environments, list_sessions and 4 more. It is published to PyPI as mcp-python-interpreter and runs with uvx.

The repository has 104 stars and 36 forks, and its last commit was on 1 Nov 2026. Conduid has no tagged release on record for it. It passes 4 of the 6 static checks Conduid ran on the repository; it does not pass No dynamic code execution and Scoped permissions. Its topics include claude-mcp, mcp-python-server, devtools and code.

Install

uvx
uvx mcp-python-interpreter
pip
pip install mcp-python-interpreter
From source
git clone https://github.com/yzfly/mcp-python-interpreter

Tools (10)

clear_sessionClear a REPL session's state and history.
ParameterTypeDescription
session_idstringSession ID to clear
install_packageInstall a Python package in the specified environment.
ParameterTypeDescription
environmentstringName of the Python environment
package_name *stringName of the package to install
timeoutintegerMaximum execution time in seconds
upgradebooleanWhether to upgrade if already installed
list_directoryList all Python files in a directory.
ParameterTypeDescription
directory_pathstringPath to directory (empty for working directory)
list_installed_packagesList installed packages for a specific Python environment.
ParameterTypeDescription
environmentstringName of the Python environment
list_python_environmentsList all available Python environments (system Python and conda environments).
list_sessionsList all active REPL sessions.
read_fileRead the content of any file, with size limits for safety.
ParameterTypeDescription
file_path *stringPath to the file
max_size_kbintegerMaximum file size to read in KB
run_python_codeExecute Python code with flexible execution modes.
ParameterTypeDescription
code *stringPython code to execute
environmentstringPython environment name (only for subprocess mode)
execution_modestringExecution mode - "inline" (default, fast, in-process) or "subprocess" (isolated)
overwritebooleanAllow replacing an existing save_as file (default: False)
save_asstringOptional filename to save the code before execution (within --dir by default)
session_idstringSession ID for inline mode to maintain state across executions
timeoutintegerMaximum execution time in seconds (only enforced for subprocess mode)
run_python_fileExecute a Python file (always uses subprocess for file execution).
ParameterTypeDescription
argumentsarrayList of command-line arguments to pass to the script
environmentstringName of the Python environment to use
file_path *stringPath to the Python file to execute
timeoutintegerMaximum execution time in seconds (default: 300)
write_fileWrite content to a file.
ParameterTypeDescription
content *stringContent to write
file_path *stringPath to the file to write
overwritebooleanWhether to overwrite if exists

Security checks

Static checks derived from the repository 10 days ago. Heuristics on the source, not an audit.

  • ✓README presentThe repository's README runs to about 681 words.
  • ✓License declaredUsable under a stated license.
  • ✓Tests presentA test suite exists in the repository.
  • ✓Dependencies pinnedDependency versions are pinned by uv.lock.
  • !No dynamic code executionScanned 3 source files and found 2 calls to eval or shell execution, in mcp_python_interpreter/server.py:102 and mcp_python_interpreter/server.py:107. Review how tool inputs reach them before granting credentials.
  • !Scoped permissionsDoesn't declare a permission scope. Assume it can do anything its process can.

What the source scan found

Transport
stdio, Streamable HTTP and HTTP with SSEmcp_python_interpreter/main.py:38, mcp_python_interpreter/main.py:123, mcp_python_interpreter/main.py:129
Starts other programs
6 callsmcp_python_interpreter/server.py:167, mcp_python_interpreter/server.py:320, mcp_python_interpreter/server.py:344
Outbound network calls
No outbound network calls
Writes or deletes files
3 callsmcp_python_interpreter/server.py:309, mcp_python_interpreter/server.py:565, mcp_python_interpreter/server.py:807
Lockfile
uv.lock

Pattern matches on the source text of 3 files: places to read, not proof of what the code does at run time.

README

The repository's README runs to about 681 words, fetched a month ago. The original in the repository is authoritative.

Read full README
Questions

About Python Interpreter

How do I install Python Interpreter?

Run uvx mcp-python-interpreter, then add the server to your MCP client's configuration.

Is Python Interpreter safe to use with an AI agent?

Its trust score is 71 out of 100 (good). It passes 4 of the 6 static checks Conduid ran on the repository; it does not pass No dynamic code execution and Scoped permissions. Conduid's scan of 3 source files found that it serves MCP over stdio, Streamable HTTP and HTTP with SSE, starts other programs (6 calls) and writes or deletes files (3 calls). Its dependencies are pinned by uv.lock. It has no ConduID identity yet, so agent calls to it are not receipted.

Is Python Interpreter still maintained?

Yes — the last commit was a month ago. The repository has 104 stars and 36 forks.

What tools does Python Interpreter provide?

Conduid read 10 tools from the source: clear_session, install_package, list_directory, list_installed_packages, list_python_environments, list_sessions, read_file, run_python_code and 2 more. 8 of them publish their parameters, listed under Tools above.

What license is Python Interpreter released under?

The repository has a license file that does not match a standard license, so read its terms before using it in a product.