python_local MCP Server
by Alec2435
An MCP Server that provides an interactive Python REPL (Read-Eval-Print Loop) environment. It allows users to execute Python code in a persistent session and access session history.
Last updated: N/A
What is python_local MCP Server?
The python_local MCP Server is a server that provides an interactive Python REPL environment. It allows users to execute Python code and maintain separate states for each session.
How to use python_local MCP Server?
To use the server, configure it in your Claude Desktop configuration file (claude_desktop_config.json). Then, use the python_repl
tool, providing the code
to execute and a session_id
. You can also access session history via the custom repl://
URI scheme.
Key features of python_local MCP Server
Persistent Python REPL sessions
Access to session history via custom URI scheme
Separate state for each session
Captures and returns stdout/stderr output
Use cases of python_local MCP Server
Interactive Python coding within a larger system
Debugging Python code
Experimenting with Python libraries
Executing Python scripts remotely
FAQ from python_local MCP Server
How do I install the server?
How do I install the server?
Configure the server in your Claude Desktop configuration file (claude_desktop_config.json) as described in the README.
How do I execute Python code?
How do I execute Python code?
Use the python_repl
tool with the code
argument containing the Python code to execute and a session_id
.
How do I access session history?
How do I access session history?
Use the repl://
URI scheme to access session history. Each session's history can be viewed as a text/plain resource.
How do I debug the server?
How do I debug the server?
Use the MCP Inspector for the best debugging experience. Launch it using npx @modelcontextprotocol/inspector uv --directory /path/to/python_local run python-local
.
How do I publish the server?
How do I publish the server?
Use the uv sync
, uv build
, and uv publish
commands to build and publish the package to PyPI. Make sure to set your PyPI credentials.