Skip to content

Prepare metadata for PyPI publishing#3

Merged
wangxin merged 1 commit into
mainfrom
prepare-pypi-metadata
Jun 11, 2026
Merged

Prepare metadata for PyPI publishing#3
wangxin merged 1 commit into
mainfrom
prepare-pypi-metadata

Conversation

@wangxin

@wangxin wangxin commented Jun 11, 2026

Copy link
Copy Markdown
Owner

Summary

Pre-publish metadata cleanup so the first PyPI release uses correct, conventional metadata.

Changes

  • __version__ now derived from installed package metadata via importlib.metadata.version("ansible-host"). Replaces a hardcoded __version__ = "0.1.0a0" that duplicated pyproject.toml. Smoke test now asserts the two match, so any future drift is caught immediately.
  • OS classifier: POSIX :: LinuxPOSIX. README has always documented "Linux, macOS, WSL" — the narrower classifier was wrong.
  • Changelog URL added to [project.urls] so PyPI's sidebar links it.
  • CHANGELOG.md added (Keep a Changelog format, SemVer), with an initial 0.1.0a0 entry covering the public API + an Unreleased section for this PR.
  • CHANGELOG.md added to sdist include so source-installs see it too.

Validation

  • twine check dist/* PASSED on both wheel and sdist
  • 37 tests pass locally; ruff clean
  • CHANGELOG.md confirmed present in the sdist

- __version__ is now derived from installed package metadata via
  importlib.metadata.version, replacing a hardcoded string that
  duplicated pyproject.toml. The smoke test asserts the two match
  to catch any future drift.
- Operating System classifier widened from POSIX :: Linux to POSIX,
  matching the documented support range (Linux, macOS, WSL).
- Added Changelog URL to [project.urls] so PyPI sidebar links it.
- Added CHANGELOG.md (Keep a Changelog format, SemVer) with an
  initial 0.1.0a0 entry and Unreleased section.
- Added CHANGELOG.md to the sdist include manifest.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Signed-off-by: Xin Wang <wangxin.wang@gmail.com>
@wangxin
wangxin merged commit fd9c305 into main Jun 11, 2026
17 checks passed
@wangxin
wangxin deleted the prepare-pypi-metadata branch June 11, 2026 07:11
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