fix(updater): discover modern Beta release tags#833
Conversation
Recognize the current -Beta.N-tauri convention while preserving historical lowercase beta tags so desktop and Android resolve the newest prerelease manifest.
PR Reviewer Guide 🔍(Review updated until commit e21c124)Here are some key observations to aid the review process:
|
appergb
left a comment
There was a problem hiding this comment.
Logical verdict: REQUEST_CHANGES (submitted as a COMMENTED review).
Fresh review of exact head 13c40b4b21fb8f95ae49352a575510f2959cbfa0 against live beta 664633f32d8d877510db25ec9d37e8b49e54d918.
Required finding — validate the complete modern tag shape, not only its tail:
is_beta_release_taginopenless-all/app/src-tauri/src/commands/settings.rs:530-538discards everything before the last-Beta.and validates only a non-empty numeric suffix plus-tauri. An exact probe of the committed predicate acceptsv-Beta.1-tauri,garbage-Beta.1-tauri,-Beta.1-tauri, andv1.3.15-Beta.2-Beta.1-tauri, although the updated release policy defines the modern form asv<X.Y.Z>-Beta.<N>-tauri.- This is observable updater behavior, not just naming hygiene:
parse_latest_beta_from_atomreturns the first accepted feed entry. A newer malformed release would therefore preempt the valid Beta entry, and both desktop and Android would compose manifest endpoints from the malformed tag (typically producing 404s and hiding the real update). - The new tests cover the positive modern form, historical lowercase form, stable exclusion, and modern-before-legacy ordering, but none places a malformed newer
*-Beta.*-tauricandidate before a valid Beta. Tighten the modern branch to the documented complete shape and add positive/negative ordering cases. Preserve the historical lowercase forms intentionally rather than removing compatibility.
What is correct and independently verified:
- The RED/GREEN behavior is real. A source-equivalent probe against the live
appergb/openlessAtom feed selects obsoletev1.3.10-4-beta-tauriwith beta's predicate and currentv1.3.14-Beta.3-tauriwith the head predicate. On the committed head, both focused tests pass; the Android test calls the sharedcrate::commands::parse_latest_beta_from_atomand then checks both manifest URLs usev1.3.15-Beta.1-tauri. - Desktop reaches that parser through
fetch_latest_beta_releaseandresolve_beta_manifest_endpoints; Android's productioncheck_updatecalls the same fetch/parser and passes its tag tobeta_manifest_urls. Exact-head Android targetcargo checkpassed. - Valid stable tags such as
v1.3.15-tauriare rejected. Current modern tags and actual legacy lowercase tags are accepted; malformed/incorrect case, empty or nonnumeric Beta numbers, missing-tauri, and trailing text are rejected. The required gap is validation of the version/prefix portion. RELEASING.md'sv<X.Y.Z>-Beta.<N>-tauripolicy matches the release workflow's modern Beta classification, prerelease handling, Beta manifest naming, Windows MSI skip, and stable-only Homebrew exclusion. It also correctly retains the historical lowercase compatibility note.
Verification:
- Head is one commit ahead / zero behind beta; merge base is beta. The conflict-free merge tree
97130d9e330b8e9bdbe8a280d1cd9c177f8de031exactly equals the head tree. - Clean detached merge-result worktree: focused tests 2/2, full Rust library 726/726, Rust-only backend 119/119, aggregate
npm test22/22, frontend production build, andcargo checkall passed. - Exact-head CI is five green. macOS ran both new tests and 726 Rust tests; Linux ran both new tests and 689 cfg-specific tests; Windows compiled the full lib-test binary, ran 130 Rust-only tests, and passed the 22-test aggregate; Android compiled the production Android target. Version sync passed on desktop jobs.
npm audit: 0 vulnerabilities.cargo audit: exit 0 with 18 allowed upstream warnings. Exact-commit gitleaks: no leaks.git diff --check: passed.- Whole-file
rustfmt --checkstill reports unrelated pre-existing formatting differences insettings.rsandcommands/mod.rs; the same differences are present on beta and none intersects the added hunks.updater_logic.rsand all added Rust hunks are rustfmt-conformant. - No UI, style, dependency, version, tag, release, or workflow file is changed.
Final drift check immediately before this review: head remains 13c40b4b21fb8f95ae49352a575510f2959cbfa0; beta remains 664633f32d8d877510db25ec9d37e8b49e54d918; all five exact-head checks remain green.
Reject malformed modern feed tags before they can preempt a valid release, while preserving the historical lowercase beta suffix.
|
Persistent review updated to latest commit e21c124 |
appergb
left a comment
There was a problem hiding this comment.
Logical verdict: APPROVE (submitted as a fresh COMMENTED review).
Fresh independent review of exact head e21c124fe5a3e3256c73ea8c343052fa9b0730ca against live beta 664633f32d8d877510db25ec9d37e8b49e54d918. I did not reuse the old head's CI or review evidence. No blocking findings remain.
The prior malformed-prefix blocker is closed:
- The modern branch now requires the complete documented shape: leading
v, exactly three non-empty ASCII-numeric version components, exact-Beta., a non-empty ASCII-numeric release number, and exact-tauritermination. The historical lowercase*-beta-tauricompatibility path remains intentionally unchanged. - A fresh source-equivalent predicate probe reproduced the old head accepting malformed prefixes, then confirmed this head rejects all 13 malformed modern shapes exercised by the regression matrix while accepting
v1.3.15-Beta.1-tauriand the real legacy formv1.3.10-4-beta-tauriand rejecting stable tags. parse_latest_beta_from_atom_skips_malformed_modern_tagsplaces malformed prefix, version, number, suffix, and repeated-marker candidates before the valid entry, so it verifies skip/order behavior rather than a positive match in isolation. The Android regression calls the same shared parser and verifies both generated manifest URLs use the valid tag.
No new edge-case regression found:
- Desktop still reaches the shared parser through
fetch_latest_beta_releaseand its Beta endpoint resolver; Android productioncheck_updateuses the same fetch/parser result and passes the validated tag tobeta_manifest_urls. - The current live release feed orders stable
v1.3.14-tauri, modernv1.3.14-Beta.3-tauri, and historicalv1.3.10-4-beta-tauri; the corrected predicate skips the stable entry, accepts the current modern release, and preserves the historical fallback. RELEASING.md'sv<X.Y.Z>-Beta.<N>-tauripolicy remains aligned with the release workflow's Beta prerelease classification, Beta-only manifest naming, Windows MSI skip, and stable-only Homebrew gate.
Fresh exact-head verification:
- Clean detached worktree: focused parser/Android regressions 4/4, full Rust library 728/728, Rust-only backend 119/119, aggregate frontend/contract suite 22/22, production frontend build, and
cargo checkall passed. - Exact-head CI is five green. macOS ran all four new cases and 728/728 Rust tests; Linux ran all four and 691/691 cfg-specific tests; Windows compiled the full lib-test target and passed 130/130 Rust-only tests; Android compiled the production
aarch64-linux-androidtarget. The 22-test aggregate and five-file version-sync gate passed on all desktop jobs; PR-Agent also passed. npm audit: 0 vulnerabilities.cargo audit: exit 0 with 18 allowed upstream warnings. Gitleaks scanned the exact two-commit range with no leaks.git diff --checkpassed.- Whole-file
rustfmt --checkstill reports unrelated existing formatting differences outside every changed hunk insettings.rsandcommands/mod.rs;updater_logic.rsand all added hunks are rustfmt-conformant.
Final drift check immediately before this review: head remains e21c124fe5a3e3256c73ea8c343052fa9b0730ca; beta remains 664633f32d8d877510db25ec9d37e8b49e54d918; head is zero behind / two ahead; merge base is beta; the conflict-free merge tree 01131665925a1b1969d567c3b74a8f15194c57aa exactly equals the head tree; all five exact-head checks remain green.
User description
Summary
vX.Y.Z-Beta.N-taurirelease-tag convention when reading the GitHub Releases Atom feed*-beta-taurireleasesv1.3.15-Beta.1-tauriover the obsoletev1.3.10-4-beta-tauriRELEASING.mdwith the modern Beta tag conventionRoot cause
The shared Atom parser only accepted tags ending in lowercase
-beta-tauri. Current releases use-Beta.N-tauri, so desktop and Android skipped every recent Beta entry and selected the last legacy release still present in the feed.Validation
v1.3.10-4-beta-taurivs expectedv1.3.15-Beta.1-tauricargo test --manifest-path openless-all/app/src-tauri/Cargo.toml --lib— 726 passedcargo test --manifest-path openless-all/app/src-tauri/backend-tests/Cargo.toml— 119 passednpm test— aggregate runner passed all 22 discovered frontend/contract testscargo check --manifest-path openless-all/app/src-tauri/Cargo.tomlcargo audit --file openless-all/app/src-tauri/Cargo.lock— no vulnerabilities; 18 allowed upstream maintenance/unsoundness warningsnpm audit— 0 vulnerabilitiesnpm run buildrustfmt;git diff --checkpassedbetamerge-tree passed cleanly against664633f32d8d877510db25ec9d37e8b49e54d918Scope
No UI changes, version bump, tag, release, or release-workflow trigger.
PR Type
Bug fix, Enhancement
Description
Recognize modern
vX.Y.Z-Beta.N-tauritag format in Atom feed parserPreserve backward compatibility with legacy
*-beta-taurisuffixReject malformed modern tags (invalid version or beta number)
Update unit tests for desktop and Android, and document new convention
Diagram Walkthrough
flowchart LR A[Atom Feed] --> B(parse_latest_beta_from_atom) B --> C{is_beta_release_tag} C -->|Legacy -beta-tauri| D[Accept] C -->|Modern -Beta.N-tauri| E[Validate version & beta number] E --> F[Accept] E --> G[Skip] D --> H[Return latest release] F --> HFile Walkthrough
settings.rs
Add is_beta_release_tag validation functionopenless-all/app/src-tauri/src/commands/settings.rs
is_beta_release_tagfunction to validate both legacy and modernbeta tag formats
parse_latest_beta_from_atomto use the new functionversion parts, non-digit beta number)
mod.rs
Add unit tests for modern beta tag detectionopenless-all/app/src-tauri/src/commands/mod.rs
parse_latest_beta_from_atom_prefers_modern_beta_tag_over_legacy_betaparse_latest_beta_from_atom_skips_malformed_modern_tagsupdater_logic.rs
Add Android beta URL tests with modern tagsopenless-all/app/src-tauri/src/android/updater_logic.rs
beta_manifest_urls_use_newest_modern_beta_tag_from_atombeta_manifest_urls_skip_malformed_modern_tags_from_atomRELEASING.md
Update RELEASING.md with modern beta tag conventionRELEASING.md
vX.Y.Z-Beta.-tauri*-beta-taurisuffix