Skip to content

Require a version bump on every PR; bump to 0.2.2 - #18

Merged
mullinmax merged 3 commits into
mainfrom
claude/version-bump-ci
Jul 18, 2026
Merged

Require a version bump on every PR; bump to 0.2.2#18
mullinmax merged 3 commits into
mainfrom
claude/version-bump-ci

Conversation

@mullinmax

Copy link
Copy Markdown
Contributor

Summary

The empty-password fix (#17) merged without a version bump, so main currently ships a behavior change under the already-released 0.2.1. This adds a CI gate so that can't happen again, and bumps the version to cover the merged fix.

  • 0.2.10.2.2 in warpedpinball/__init__.py (the single source of truth; pyproject.toml reads it dynamically).
  • New version-bump CI job (pull_request only): fails the PR unless __version__ is strictly greater than the base branch's.
  • scripts/check_version_bump.py: reads the head __version__ and the base branch's version (from git show <base>:warpedpinball/__init__.py), and requires head > base. A missing base file (brand-new package) passes. Uses packaging for PEP 440 ordering when available, with a numeric-release-plus-suffix fallback so a release supersedes its own pre-release (0.2.0rc1 < 0.2.0).
  • Unit tests cover the comparison logic.

The existing version-check job (tag ↔ package agreement, on release) is unchanged; this adds the missing "did this PR actually bump?" gate.

Testing

  • python -m pytest tests/test_check_version_bump.py — passes.
  • ruff check on the new files — clean.
  • Ran the script against origin/main: Version bump check OK: 0.2.1 -> 0.2.2.

Note

The gate requires a bump on every PR (including docs/CI-only ones). If you'd rather allow exceptions, a follow-up can add a skip-version-bump label check — say the word and I'll wire it in.

🤖 Generated with Claude Code

https://claude.ai/code/session_014Y49XvgGpmTHrYLDeTvmbA


Generated by Claude Code

mullinmax and others added 2 commits July 18, 2026 20:17
Some Vector boards have no password configured, which the firmware
authenticates by signing with an empty-string HMAC key. The client
conflated an empty password with "no password set": the Machine.password
property coerced "" to the $VECTOR_PASSWORD fallback, and both the auth
preflight and the HTTP transport rejected a falsy password outright, so an
empty password could never be used.

Distinguish None (unset — still falls back to the environment and raises
AuthenticationRequiredError when nothing is configured) from "" (a valid
empty password that is signed as such):

- Machine.password returns an explicitly-set empty string instead of the
  env fallback; only None falls back.
- Machine._preflight_auth and HttpTransport._send guard on `is None`
  rather than falsiness.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_014Y49XvgGpmTHrYLDeTvmbA
The empty-password fix (#17) merged without a version bump, so main could
ship a behavior change under the already-released 0.2.1. Add a CI gate that
fails a pull request unless it raises __version__ above the base branch, and
bump to 0.2.2 to cover the merged fix.

- scripts/check_version_bump.py compares the head __version__ against the
  base branch's (read from git) and requires head > base; a missing base
  file (new package) passes. PEP 440 ordering via packaging when available,
  with a numeric-plus-suffix fallback.
- ci.yml gains a version-bump job (pull_request only) that runs it against
  the PR base sha.
- Unit tests cover the comparison logic.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_014Y49XvgGpmTHrYLDeTvmbA
@github-actions

Copy link
Copy Markdown

Coverage report

Total coverage: 100.00% (0.00% vs base 100.00%)

@mullinmax
mullinmax marked this pull request as ready for review July 18, 2026 20:35
@mullinmax
mullinmax merged commit b3ec41e into main Jul 18, 2026
12 checks passed
@mullinmax
mullinmax deleted the claude/version-bump-ci branch July 18, 2026 20:35
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