Move release notes to GitHub Releases and derive the version from the tag

Merged
KL
5d ago
+78-37

The same change as Kludex/uvicorn#3261. A release is now a single step: create the GitHub release. There is no release PR, since the version comes from the tag and the release notes live only in GitHub Releases.

Release notes

  • CHANGELOG.md is kept for history up to 0.0.34 and is no longer updated. It points to GitHub Releases at the top.
  • The docs Changelog nav entry, the README link and the Changelog project URL point to the releases page. docs/changelog.md, which only included CHANGELOG.md, is removed.

Sponsorship header

  • sponsors.yml now puts a "This project needs your help! Let's make this project sustainable together" line, with the second sentence linked to the 2027 sponsorship fund post, at the top of every published release.
  • The header no longer depends on the sponsor list. Before, an empty or unreachable list left the release untouched; the list is empty today.
  • The header and the credits are checked separately, so rerunning the workflow after a failed fetch adds the credits without repeating the header.

Version

  • uv-dynamic-versioning reads the version from the Git tag. Tags stay unprefixed, like 0.0.35.
  • python_multipart.__version__ is imported from python_multipart/_version.py, which Hatchling writes at build time. check-sdist is told the file exists only in the sdist.
  • publish.yml fetches the full history, since a shallow checkout does not fetch the tags. It takes the version for the PyPI environment URL from the tag name, because uvx hatchling version cannot load the new version source.
  • build-constraint-dependencies pins hatchling, uv-dynamic-versioning and their dependencies, since uv does not lock build dependencies.

Checked locally

  • A clone tagged 0.0.35 builds as 0.0.35, and a commit after 0.0.34 builds as 0.0.35.dev1+c725db3.
  • scripts/check, scripts/test and scripts/rename pass, with coverage at 100%, and the docs build.

Notes

  • Building from a GitHub source tarball gives 0.0.0. Downstream packagers who build that way need to build from the sdist, or set UV_DYNAMIC_VERSIONING_BYPASS to the version.
  • The docs are on GitHub Pages, which has no redirects, so the old /changelog/ page returns a 404.
  • A fresh checkout needs scripts/setup before import python_multipart works, because python_multipart/_version.py is generated.

Session: pi --session 01a20ccc-942b-72f1-90ed-ac23bd733985