Skip to content

fix(version): accept alpha.0 anchors in dev builds - #10

Open
bsinou wants to merge 1 commit into
devfrom
fix/wpb-29713-dev-build-anchor-zero
Open

bsinou wants to merge 1 commit into
devfrom
fix/wpb-29713-dev-build-anchor-zero

Conversation

@bsinou

@bsinou bsinou commented Nov 12, 2026

Copy link
Copy Markdown
Collaborator

Description

Release mode (release-version.sh) takes a pre-release numbered 0 as an anchor: v5.1.0-alpha.0 on the last production commit makes the next alpha 5.1.0-alpha.1. Build mode (compute-version.sh) skipped those tags, because its pre-release pattern starts at 1. So a branch whose only reachable v tag is an anchor failed every dev build with "no GA or pre-release tag is reachable". It happened on wire-avs-service, on release/5.1 and dev.

Dev builds now accept X.Y.Z-alpha|beta|rc.0 when they look for the nearest tag, and come out as 5.1.0-alpha.0.<ts>.g<sha7>. A tag build of an anchor is still refused: .0 opens a line but is never a version.

When several tags point at the nearest commit, the highest in SemVer now wins, as in release mode. A GA still beats its own pre-releases (v5.3.0 over v5.3.0-rc.2). An anchor now beats an older GA on the same commit (v5.1.0-alpha.0 over v5.0.80), where the old rule picked the GA and built 5.0.81-... while release mode prepared 5.1.0-alpha.1.

Two new tests cover a dev build after an anchor and an anchor next to an older GA. version/README.md gets the anchor rule and a row in the table. make ci passes.

Related Issue

  • WPB-29713

Types of changes

  • 🐞Bug fix – A non-breaking change that resolves an existing issue.
  • ✨New feature – A non-breaking change that introduces new functionality
  • 💥Breaking change – A change that alters existing functionality in a way that is not backward compatible.
  • 🧼Code Cleanup - Code refactoring or improvements with no functional impact.
  • 📖Documentation – Updates or additions to documentation only.
  • 🛠️Tooling - fix or add tools in the repository to build / lint / ...

@bsinou
bsinou requested a review from a team as a code owner November 12, 2026 18:40

This branch has not been deployed

No deployments
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