fix: add run.sh launcher to handle venv path breakage on repo move - #138
Open
miles-on-nightshift wants to merge 1 commit into
Open
Conversation
Venv shebangs embed absolute paths — moving or renaming the repo directory silently breaks the server (Claude Desktop reports "connected" then immediately disconnects). run.sh detects a broken venv and auto-recreates it before launching, so users no longer need to manually rebuild after relocation. README "From Source" config updated to point at run.sh instead of the raw venv python path. Windows config unchanged (run.sh not applicable). Closes datafund#131
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Closes #131
What
Adds
run.shat the repo root — a thin launcher that auto-detects a broken venv (caused by moving/renaming the repo directory) and recreates it before starting the MCP server.Why
Python venvs embed absolute paths in shebang lines. Moving or renaming the repo makes every
venv/bin/script fail. Claude Desktop shows "Server started and connected" then immediately disconnects — the actual error (bad interpreter) is buried in stderr and hard to diagnose.Changes
run.sh— 10-line launcher with self-healing venv logicREADME.md— macOS/Linux "From Source" config updated to userun.shinstead ofvenv/bin/pythondirectly; on-chain provenance config also updatedrun.shnot applicable on Windows)Test plan
./run.sh→ server starts normally./run.sh→ venv recreated automatically, server startsrun.sh: connect/disconnect cycle gone after repo move