Skip to content

Bump to 0.3.0 and guard release tag/version drift - #25

Merged
nicholsn merged 1 commit into
mainfrom
release/0.3.0
Aug 4, 2026
Merged

Bump to 0.3.0 and guard release tag/version drift#25
nicholsn merged 1 commit into
mainfrom
release/0.3.0

Conversation

@nicholsn

@nicholsn nicholsn commented Aug 4, 2026

Copy link
Copy Markdown
Owner

Why

The v0.3.0 publish run failed. Tests and uv build passed, but the upload got:

400 File already exists ('lokf-0.2.0-py3-none-any.whl', ...)

pyproject.toml was never bumped before the v0.3.0 tag was cut, so uv build produced lokf-0.2.0.* and PyPI correctly refused to overwrite the existing 0.2.0 files. Nothing was wrong with the package itself.

What

  • Bump 0.2.00.3.0 (pyproject.toml + uv.lock, via uv version 0.3.0).
  • Add a tag/version guard to the build job in publish.yml. On a release event it compares the tag (minus the v) to uv version --short and fails immediately on mismatch, so a missed bump reads as "bump the version, merge, then re-tag" instead of an opaque PyPI 400 two jobs later. Skipped on workflow_dispatch, which has no tag.

Verification

  • uv run --group dev pytest -q → 158 passed
  • uv buildlokf-0.3.0.tar.gz, lokf-0.3.0-py3-none-any.whl
  • uvx twine check dist/* → PASSED on both
  • Guard logic exercised both ways: passes on v0.3.0, fails on a mismatched tag
  • 0.3.0 confirmed unused on PyPI (published: 0.1.0, 0.2.0)

After merge

The existing v0.3.0 tag/release point at the un-bumped commit, so they get deleted and recreated at the merge commit to retrigger publish.

The v0.3.0 release built 0.2.0 artifacts because pyproject.toml was
never bumped, so PyPI rejected the upload with "400 File already
exists". Bump the version, and fail the build job up front when a
release tag doesn't match the packaged version instead of letting it
surface as an opaque error at upload time.
@nicholsn
nicholsn merged commit e91d050 into main Aug 4, 2026
2 checks passed
@nicholsn
nicholsn deleted the release/0.3.0 branch August 4, 2026 23:32
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