Skip to content

fix(release): compare version components as bounded integers - #182

Merged
rldyourmnd merged 1 commit into
mainfrom
fix/release-version-compare
Sep 19, 2026
Merged

rldyourmnd merged 1 commit into
mainfrom
fix/release-version-compare

Conversation

@rldyourmnd

Copy link
Copy Markdown
Contributor

Summary

The auto-release resolve job failed on the first double-digit patch bump (run 35473190210): sort -t. -k1n -k2n -k3n reads an unbounded field like 9.10 as the float 9.1, so 0.9.10 ordered below 0.9.9 and the monotonicity check refused the identity — correctly, given what it was told.

  • Tag ordering: bound every key to its own field (-k1.6,1nr -k2,2nr -k3,3nr) so gds-v0.9.10 sorts above gds-v0.9.9 — the same bug would have struck the newest-first tag walk as soon as 0.9.10 existed.
  • Greater-than check: replaced the sort-based comparison with a numeric per-component awk compare — no external sort semantics at all.

Verified locally: gds-v1.0.0 > gds-v0.10.0 > gds-v0.9.10 > gds-v0.9.9 > gds-v0.9.7, and 0.9.10 > 0.9.9 / 0.9.9 not greater than 0.9.10.

Merging this PR re-triggers the release pipeline; the resolve job should then mint gds-v0.9.10 / sequence 66 from the last published envelope.

Test plan

  • Local comparator verification incl. double-digit and major/minor boundaries
  • Release run resolves gds-v0.9.10 on the merge push

Generated with Devin

The resolve job failed on the first double-digit patch bump: sort -n
parses an unbounded field like "9.10" as the float 9.1, so 0.9.10
ordered below 0.9.9 and the monotonicity check correctly refused the
identity. Bound every sort key to its own field (-kN,N) and replace the
sort-based greater-than test with a numeric per-component awk compare.
@rldyourmnd
rldyourmnd merged commit 54d8d7c into main Sep 19, 2026
8 checks passed
@rldyourmnd
rldyourmnd deleted the fix/release-version-compare branch September 19, 2026 22:47
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