Skip to content

Fix the Python wheel build (CI has been red since 2025-12) - #7

Merged
JaviMaligno merged 1 commit into
mainfrom
fix/python-sdist-readme
Jul 29, 2026
Merged

Fix the Python wheel build (CI has been red since 2025-12)#7
JaviMaligno merged 1 commit into
mainfrom
fix/python-sdist-readme

Conversation

@JaviMaligno

Copy link
Copy Markdown
Owner

Every CI run on main since 2025-12 has failed on build-python:

OSError: Readme file does not exist: README.md

Cause

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 lives outside the packaged tree — so hatchling cannot read the file project.readme points at.

The tell is that the sdist listing contains README.md and the build still fails: the entry is a link, not a file.

Fix

Replaced it with a real file: a short Python-specific README covering install and configuration, linking to the repository for the full tool reference. Kept deliberately short so the two copies have little room to drift.

Verification

Reproduced the failure locally, then confirmed the fix:

$ uv build
Successfully built dist/postgresql_mcp-0.2.0.tar.gz
Successfully built dist/postgresql_mcp-0.2.0-py3-none-any.whl

$ tar -xzOf dist/*.tar.gz --wildcards "*/README.md" | head -1
# postgresql-mcp (Python)

Found while working on #4 — the red job made it impossible to tell whether that PR was green. Worth merging first.

🤖 Generated with Claude Code

https://claude.ai/code/session_01LVnEdm6smNC5ZJzghc7WRY

`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) <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01LVnEdm6smNC5ZJzghc7WRY
@JaviMaligno
JaviMaligno merged commit f1bc4b3 into main Jul 29, 2026
7 checks passed
@JaviMaligno
JaviMaligno deleted the fix/python-sdist-readme branch July 29, 2026 16:14
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant