From aff62f4cffaabe968ea0a739101e440cf381c88d Mon Sep 17 00:00:00 2001 From: Javi Date: Wed, 29 Jul 2026 17:02:46 +0100 Subject: [PATCH] fix(python): ship a real README so the wheel builds MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit `build-python` has failed on every CI run since 2025-12 with: OSError: Readme file does not exist: README.md python/README.md was a symlink to ../README.md. `uv build` builds the wheel from the source distribution, and inside that tarball the link dangles — its target sits outside the packaged tree — so hatchling cannot read the file that `project.readme` points at. Replaced with a real, deliberately short README that covers install and configuration and links to the repository for the rest, so the two copies have little room to drift. Verified locally: both sdist and wheel now build, and the sdist carries the file rather than a link. Co-Authored-By: Claude Opus 5 (1M context) Claude-Session: https://claude.ai/code/session_01LVnEdm6smNC5ZJzghc7WRY --- python/README.md | 58 +++++++++++++++++++++++++++++++++++++++++++++++- 1 file changed, 57 insertions(+), 1 deletion(-) mode change 120000 => 100644 python/README.md diff --git a/python/README.md b/python/README.md deleted file mode 120000 index 32d46ee..0000000 --- a/python/README.md +++ /dev/null @@ -1 +0,0 @@ -../README.md \ No newline at end of file diff --git a/python/README.md b/python/README.md new file mode 100644 index 0000000..ca194e7 --- /dev/null +++ b/python/README.md @@ -0,0 +1,57 @@ +# postgresql-mcp (Python) + +MCP server for PostgreSQL database operations. Works with Claude Code, Claude Desktop, Cursor, and any MCP-compatible client. + +This is the **Python** implementation. A TypeScript implementation with the same +tool set lives in [`/typescript`](https://github.com/JaviMaligno/postgres_mcp/tree/main/typescript) +and is published to npm as `postgresql-mcp`. + +> This file used to be a symlink to the repository root README. That made the +> published source distribution carry a dangling link, which broke the wheel +> build — so it is a real file now, deliberately kept short. **The full +> documentation is in the [repository README](https://github.com/JaviMaligno/postgres_mcp#readme).** + +## Install + +```bash +pipx install postgresql-mcp +``` + +## Configure + +```bash +claude mcp add postgres -s user \ + -e POSTGRES_HOST=localhost \ + -e POSTGRES_USER=your_user \ + -e POSTGRES_PASSWORD=your_password \ + -e POSTGRES_DB=your_database \ + -- postgresql-mcp +``` + +| Variable | Required | Default | Description | +|----------|----------|---------|-------------| +| `POSTGRES_HOST` | | `localhost` | Database host | +| `POSTGRES_PORT` | | `5432` | Database port | +| `POSTGRES_USER` | ✅ | | Database user | +| `POSTGRES_PASSWORD` | ✅ | | Database password | +| `POSTGRES_DB` | ✅ | | Database name | +| `POSTGRES_SSLMODE` | | `prefer` | SSL mode | +| `ALLOW_WRITE_OPERATIONS` | | `false` | Enable INSERT/UPDATE/DELETE | +| `QUERY_TIMEOUT` | | `30` | Query timeout in seconds | +| `MAX_ROWS` | | `1000` | Maximum rows returned per query | + +## What it provides + +- **14 tools** — query execution, schema exploration, table analysis, EXPLAIN plans +- **4 prompts** — guided workflows for exploration, query building, performance analysis and documentation +- **Resources** — browsable database structure as markdown +- **Read-only by default**, with SQL injection prevention and credential protection + +See the [full documentation](https://github.com/JaviMaligno/postgres_mcp#readme) for +the complete tool reference, security model, and the +[installation guide](https://github.com/JaviMaligno/postgres_mcp/blob/main/docs/INSTALLATION.md) +for database permissions and remote connections. + +## License + +MIT