From d6b2b07faf8376d5e1fff536c45cd2e52cc18f3a Mon Sep 17 00:00:00 2001 From: Nigel Tatschner Date: Wed, 27 May 2026 17:19:47 +0100 Subject: [PATCH 1/2] fix(ci): release.yml prerelease flag broken by tray- prefix MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Every tray release since v1.8.5 was wrongly flagged Pre-release in the GitHub UI, including bare-semver lives like tray-v1.8.7 and tray-v1.8.8. Root cause: the 2026-05-23 track split renamed tray tags from v1.8.x to tray-v1.8.x. The release-creation step's prerelease test was `contains(github.ref_name, '-')` — perfectly correct under the pre-split scheme where bare semver had no hyphen and prerelease suffixes added one, but silently broken the moment a literal `tray-` prefix landed in every ref name. The expression now evaluates true for every tray tag, so every release came out flagged Pre-release. Fix: test the channel tokens directly: contains(ref_name, '-alpha') || contains(ref_name, '-beta') || contains(ref_name, '-rc') This is robust against further tag-prefix changes and explicit about the closed set of pre-release channels the promote script ever produces (alpha / beta / rc). Backfix for the wrongly-flagged historical releases was applied via `gh release edit tray-v1.8.7 --prerelease=false` and `gh release edit tray-v1.8.8 --prerelease=false` separately. Reference: tracked from a comment on tray-v1.8.8 showing as "Pre-release" instead of "Latest" on the GH releases page. --- .github/workflows/release.yml | 16 ++++++++++++---- 1 file changed, 12 insertions(+), 4 deletions(-) diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 0d7adc5..0e61240 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -378,10 +378,18 @@ jobs: tag_name: ${{ github.ref_name }} name: ${{ github.ref_name }} draft: true - # Anything with a hyphen (rc, beta, alpha, etc.) is a pre-release; - # only bare semver like tray-v0.2.0 gets marked Latest on the - # GH releases page. - prerelease: ${{ contains(github.ref_name, '-') }} + # Only bare semver (e.g. `tray-v0.2.0`) gets marked Latest on + # the GH releases page; anything with an `-alpha` / `-beta` / + # `-rc` channel suffix is a pre-release. + # + # IMPORTANT: do NOT test for a hyphen in `ref_name` — the + # post-2026-05-23 track split prefixes every tray tag with + # `tray-`, so the previous `contains(ref_name, '-')` form + # evaluated true for live tags too. Result: every release + # from tray-v1.8.5 onward was wrongly flagged Pre-release in + # the GH UI. Match against the channel tokens explicitly so + # the test is stable against any future tag-prefix change. + prerelease: ${{ contains(github.ref_name, '-alpha') || contains(github.ref_name, '-beta') || contains(github.ref_name, '-rc') }} # `generate_release_notes: false` — our per-component changelog # in release-body.md replaces GH's auto-generated notes, which # would otherwise leak platform-only commits into the tray From baa177e9a3dc34137ab637eb32fafde003fc81f0 Mon Sep 17 00:00:00 2001 From: Nigel Tatschner Date: Wed, 27 May 2026 19:24:56 +0100 Subject: [PATCH 2/2] fix(ci): also set make_latest explicitly for live tray releases prerelease and make_latest are independent flags. After today's backfix flipped tray-v1.8.7 / tray-v1.8.8 to prerelease=false, the Latest badge stayed on tray-v1.8.6 because gh release edit --prerelease doesn't touch make_latest. Set make_latest in the release-creation step too so future live promotions grab the Latest badge at creation rather than requiring a follow-up gh release edit --latest. --- .github/workflows/release.yml | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 0e61240..826ca20 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -390,6 +390,16 @@ jobs: # the GH UI. Match against the channel tokens explicitly so # the test is stable against any future tag-prefix change. prerelease: ${{ contains(github.ref_name, '-alpha') || contains(github.ref_name, '-beta') || contains(github.ref_name, '-rc') }} + # `make_latest` is independent of `prerelease`. Setting it + # explicitly here so live tags grab the Latest badge at + # creation time. Without this, when a release was previously + # mis-created as prerelease and then edited to non-prerelease + # (the 2026-05-27 backfix of tray-v1.8.7 / tray-v1.8.8), the + # Latest badge stayed on the older live tag — because flipping + # `prerelease` doesn't touch `make_latest`. Quoted strings + # because the action expects "true"/"false"/"legacy", not + # YAML booleans. Mirrors the prerelease expression inverted. + make_latest: ${{ (contains(github.ref_name, '-alpha') || contains(github.ref_name, '-beta') || contains(github.ref_name, '-rc')) && 'false' || 'true' }} # `generate_release_notes: false` — our per-component changelog # in release-body.md replaces GH's auto-generated notes, which # would otherwise leak platform-only commits into the tray