feat: support installing the latest beta release via version: beta#441
feat: support installing the latest beta release via version: beta#441avallete wants to merge 1 commit into
version: beta#441Conversation
The `latest` channel resolves through the GitHub `/releases/latest` endpoint, which never returns prereleases, so there was no way to track the CLI beta channel — any other value was treated as an exact version. Add a `beta` channel that lists releases and installs the most recent beta prerelease. This lets consumers surface (and fix) breakages early. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01APKXLPMGXsnWUSU3i16Lfv
jgoux
left a comment
There was a problem hiding this comment.
Findings
-
P2:
src/main.tsfetches only the default first page of GitHub releases when resolvingversion: beta, despite the comment saying “list all releases.” If the latest beta falls off page 1,version: betawill fail with “no beta release found” even though a beta exists. I’d addper_page=100at minimum, and ideally follow pagination until a beta is found or the release list is exhausted.
Line 212 in 3dacd93
-
P3:
action.ymlstill saysgithub-tokenis used to resolve only the latest release. README was updated to saylatest/beta, so the action metadata should match.
Lines 8 to 9 in 3dacd93
Test Gap
The mocked unit coverage is good, but no workflow/e2e path exercises version: beta against the live release API and real archive download. Current matrices still cover only explicit versions and latest; I’d add a small beta smoke case, probably one OS only to keep runtime sane.
setup-cli/.github/workflows/ci.yml
Line 49 in 3dacd93
setup-cli/.github/workflows/e2e.yml
Line 42 in 3dacd93
Verification
I reviewed PR 441 at 3dacd93e8f53a2229ed8c0a31d18cdfedf851fcf against main, checked the live Supabase CLI releases API, confirmed the current latest beta has the expected archive assets, and ran the repo validation successfully after the CI setup step:
bun install --frozen-lockfile && bun run ciResult: format, lint, and 27 tests passed.
What kind of change does this PR introduce?
The
latestchannel resolves through the GitHub/releases/latestendpoint, which never returns prereleases, so there was no way to track the CLI beta channel — any other value was treated as an exact version.Add a
betachannel that lists releases and installs the most recent beta prerelease. This lets consumers surface (and fix) breakages early.