Repository navigation
fix(release): a newer beta no longer blocks promoting a tested beta - #1897
Merged
Merged
Conversation
The native release-order check refused a stable whenever any newer beta was published. Betas ship several times a day, so a candidate that ran on sites for a week could never be promoted. A stable is now refused only when a newer stable exists; betas keep the old rule. AGENTS.md says so and describes the real hotfix path: the workflow runs only from master, so a fix ships as the next beta and promotes. Co-Authored-By: Claude Opus 5.5 <[email protected]>
Codex Review SummaryThis comment shows the latest Codex review activity on this pull request.
ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings. |
A stable may now be promoted after newer betas ship, so GitHub lists it above a higher beta. resolveChannel took the first match, so every beta box got the stable and skipped the newest beta until the next beta shipped. The walk now keeps the higher of the first stable and the first beta, and stops at the first beta. The release-order check refuses any beta below a published release, so nothing listed after it can rank higher. Stable boxes still stop at the first stable. Tests: the reviewer's ordering fails on the old code and passes now, a paged list stops at the first beta, and the Python checker pins the rules the walk relies on. Co-Authored-By: Claude Opus 5.5 <[email protected]>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Item G2-fix of the stable plan.
Problem
scripts/check-native-release-order.pyrefuses any tag that ranks below a published release, betas included.native-release.ymlruns it before the stable branch.Concrete case: sites test
v0.158.0-beta.3for a week. Meanwhile master shipsv0.159.0-beta.1. Dispatching stablev0.158.0withsource_beta=v0.158.0-beta.3then fails withv0.158.0 is older than published v0.159.0-beta.1. Between 13 and 27 October about 30 betas shipped, so every stable attempt would hit this.Fredrik decided on 27 October that betas keep shipping while a stable candidate is tested (no beta freeze). The plan's decision 1 recommended a freeze; this PR follows the owner's choice. The plan's gate G6 ("No newer beta is published") and its G2-fix line ("Write the beta freeze into AGENTS.md") are now stale and need the same change.
The old order check also kept a rule the updater relied on: the first release GitHub lists is the newest.
resolveChanneltook the first match. Once a stable can be promoted after newer betas, GitHub lists it above them, and every beta box would take the stable and skip the newest beta until the next beta shipped.Master's AGENTS.md also gave no hotfix path for the native line.
Change
source_betais a publishedv0.X.Y-beta.Nof the same version.resolveChannelon beta keeps the higher of the first stable and the first beta listed, and stops at the first beta. Since no beta may rank below a published release, nothing listed after it can rank higher, so the walk stays as short as before. Stable boxes still stop at the first stable.package.jsonthere, so no patch branch exists.Tests
go test -race ./internal/selfupdate/ ./cmd/ftw/,go vet,go build ./...: pass.TestCheck_BetaPrefersNewerBetaListedBelowPromotedStableserves[v0.158.0, v0.159.0-beta.1, v0.158.0-beta.3]. On the old updater, boxes onv0.157.2-beta.1andv0.158.0-beta.3were offeredv0.158.0, and a box onv0.159.0-beta.1sawv0.158.0as latest. Now all three seev0.159.0-beta.1, and a stable box still getsv0.158.0.TestCheck_BetaWalksPastStableToTheFirstBetaAndStops: a stable on page 1 and a beta on page 2 give the beta, and page 3 is never fetched. It fails on the old updater.python3 -m unittest discover -s scripts -p 'test_*.py': 59 tests pass. On master,test_newer_beta_does_not_block_tested_stableerrors (the audit repro, caa-67). New Python tests pin the rules the updater relies on: after a late stable, the next beta passes and a beta on the promoted line is refused; a newer stable on a later page blocks; a draft stable does not.Risk
Low. Promoting an older line after a newer beta exists is now possible. Nothing ties a stable to a recent line beyond the workflow's
source_betachecks. Beta boxes never downgrade (the updater'sisNewerguard). Stable boxes get the stable as before. The schema check still compares the stable with the release below it.The updater fix helps only boxes that run it. It must be in the candidate beta. A beta box still on an older beta when the stable ships will take the stable, then the next beta.
🤖 Generated with Claude Code