Release Workflow¶
The release train is fully automated by GitHub Actions. The entry point is
.github/workflows/release.yml, which runs whenever main is updated (or via
workflow_dispatch). The jobs fire in the following order:
check_buildinspects the diff for packaging-affecting paths. If the previous merge tomainalready produced wheels, the job can skip forcing a rebuild; otherwise it marks the next stage to rebuild artifacts.check_releaserunspython-semantic-release --noopto decide whether a new semantic version should be cut. The version number is emitted as a job output so downstream steps share the result.buildreuses./.github/workflows/build.ymlto invokecibuildwheeland build the source distribution. The job only executes when either step 1 requested a rebuild or step 2 detected a release-worthy change.releaseruns on Ubuntu 22.04, downloads the wheel and sdist artifacts, runsgit-cliffto prepend a changelog entry, and letspython-semantic-releasepublish the tag and PyPI release. A release PR is raised fromcreate-pull-request/patchback tomainso the generated changelog lands in the history.
Local dry runs¶
Use these commands before landing changes that affect packaging or release:
# Preview the changelog range that git-cliff will generate
git cliff <previous-release>..HEAD --config cliff.toml --tag v<next-version> --output release-notes.md
# Mirror the semantic-release decision locally
uv run python -m semantic_release version --noop --verbosity DEBUG
If the changelog command emits no user-facing bullets, the automation will post
- No user-facing changes. instead of empty markdown.
Triggering a release by hand¶
Kick off the workflow from the Actions → Release → Run workflow menu. The
workflow_dispatch input runs through the same steps as a commit to main,
including artifact build, git-cliff, and publishing. Double-check the
resulting PR titled Release <X.Y.Z> for the changelog diff before merging.