Skip to content

Add release automation and is-upload input#13

Merged
arcivanov merged 1 commit intomasterfrom
release-automation
Mar 8, 2026
Merged

Add release automation and is-upload input#13
arcivanov merged 1 commit intomasterfrom
release-automation

Conversation

@arcivanov
Copy link
Member

@arcivanov arcivanov commented Mar 7, 2026

Summary

  • version_tool.py (new): AST-based tool for reading and modifying the version variable in PyBuilder build.py files. Stdlib only, compatible with Python 3.9-3.15+. Performs static analysis to prove version determinism, refusing to operate on files with dynamic versions, conditional assignments, exec/eval, star imports, or globals()/vars()/locals() calls.

  • action.yml: New is-upload input replaces the ad-hoc PYB_EXTRA_ARGS=+upload shell step pattern. New release automation inputs (auto-release, auto-release-version, auto-github-release, auto-bump-dev, release-tag-prefix, release-title-template, build-py-path, github-token) with new steps for release detection, version stripping, atomic tag+commit push (distributed lock for multi-arch builds), GitHub Release creation, and dev version bump.

  • test.yml: New test jobs for version_tool.py across Python 3.9/3.12/3.14, release detection, is-upload functionality, and end-to-end integration test. The integration test dispatches a workflow on pybuilder/build-integration-test that exercises the full release cycle on a real push event: detect [release], strip .dev, build, tag, GitHub release, and bump dev version.

  • README.md: Updated advanced example, added Upload and Release Automation sections with migration guide. Updated actions/checkout and actions/setup-python version references from @v2 to @v5/@v6.

Test plan

  • CI passes: existing test matrix (OS x Python x venv x homebrew)
  • CI passes: test-version-tool across Python 3.9, 3.12, 3.14
  • CI passes: test-release (release detection without push/upload)
  • CI passes: test-is-upload (upload flag propagation)
  • CI passes: integration-test (end-to-end release flow on pybuilder/build-integration-test)

@arcivanov arcivanov force-pushed the release-automation branch 6 times, most recently from 33a292f to 0dbee2c Compare March 8, 2026 01:45
@arcivanov arcivanov force-pushed the release-automation branch from 0dbee2c to dab445a Compare March 8, 2026 01:57
@arcivanov arcivanov merged commit 5253722 into master Mar 8, 2026
125 checks passed
@arcivanov arcivanov deleted the release-automation branch March 8, 2026 03:15
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