Skip to content

Refine desktop update checking and labels#2131

Open
iPixelGalaxy wants to merge 3 commits intopingdotgg:mainfrom
iPixelGalaxy:feature/update-qol-changes-and-bug-fixes
Open

Refine desktop update checking and labels#2131
iPixelGalaxy wants to merge 3 commits intopingdotgg:mainfrom
iPixelGalaxy:feature/update-qol-changes-and-bug-fixes

Conversation

@iPixelGalaxy
Copy link
Copy Markdown

@iPixelGalaxy iPixelGalaxy commented Apr 17, 2026

  • Compare stable and nightly feeds to pick the best candidate
  • Preserve no-update messages for older nightly builds
  • Show available update versions in the settings and sidebar UI

What Changed & Why

  • Changed the update check behavior to 2 seconds instead of 15 seconds after app startup.
    • Reason: The user may want to know there is a newer version available before they make a prompt, but still gives enough time for other UI elements to load.
  • Added a check in case the user manages to click the update button within 2 seconds so the auto check doesn't run.
    • Reason: This was implemented before the change to the 2 second to 15 second check and seems like a good redundancy to keep in place in case that time is either changed back or other changes are made.
  • Nightly branch track will update to latest stable build if the Nightly build is an older version than latest Stable.
    • Reason: There may be cases where the nightly build is lagging behind a full release, the user will be able to update to Stable while there isn't a nightly, but retain their nightly track and get a prompt to update to the latest nightly once one is available.
  • Update available label now shows the version number in it as: "Update available: "
    • Reason: Clarity on what version you are updating to.
  • In settings About -> Version if there is an update available it now displays what version you are updating to as "Update available: "
    • Reason: Clarity on what version you are updating to.
  • Added a toast for when the user interacts with the Check for Updates button.
    • Reason: This way it is much clearer for the user what happen when they clicked the button.

UI Changes

All the UI changes and testing is showcased in this video:

Video.mp4

I built 3 identical versions with the follow types Stable 0.0.20, Nightly 0.0.19 and Nightly 0.0.21 to demonstrate the different errors and how they appear.

Checklist

  • This PR is small
    • I understand that this PR is not quite as small as I wish it to be and understand that this may not be accepted or implemented in a different way, any code provided can be used in any way elsewhere should the ideas in this PR be considered useful.
  • This PR is focused
  • I explained what changed and why
  • I included before/after screenshots for any UI changes
  • I included a video for animation/interaction changes

Note

Medium Risk
Changes desktop auto-update selection logic (including nightly/stable feed arbitration and downgrade behavior), which could affect who gets offered an update and when. UI changes are low risk, but incorrect version comparison or feed switching could cause missed/incorrect update prompts.

Overview
Desktop updater now performs smarter checks on the nightly track. When on nightly, it sequentially checks both latest and nightly feeds, collects candidates, selects the best version via new semantic/nightly-aware comparison helpers, and restores the chosen provider before marking the update as available.

Update-state messaging and timing are refined. Startup update checks run sooner (2s vs 15s) and user-initiated checks cancel any pending startup check; reduceDesktopUpdateStateOnNoUpdate now preserves an optional non-error message (e.g., nightly older/no newer nightly) so the UI can show accurate “no update” reasons.

Web UI labels are clearer for available updates. Adds getDesktopUpdateAvailableLabel and updates settings + sidebar pill to display Update available: <version> (preferring downloaded), and settings now shows an info toast when a manual “Check for Updates” completes with no update (including polling while the desktop bridge is still checking).

Reviewed by Cursor Bugbot for commit db5c50d. Bugbot is set up for automated code reviews on this repo. Configure here.

Note

Add dual-feed nightly update checking and version labels to desktop updater

  • On the nightly channel, the updater now checks both stable and nightly feeds sequentially, selects the best candidate newer than the current version, and surfaces specific messages when no newer build exists (NIGHTLY_BUILD_OLDER_MESSAGE, NO_NEWER_NIGHTLY_BUILD_MESSAGE).
  • Adds compareDesktopVersions and selectBestDesktopUpdateCandidate in updateChannels.ts to rank stable vs. nightly builds, treating non-nightly as newer than nightly at the same base version.
  • The settings panel and sidebar pill now display Update available: <version> (preferring the downloaded version) instead of a generic label, and show an info toast when no update is found after a manual check.
  • Reduces AUTO_UPDATE_STARTUP_DELAY_MS from 15000ms to 2000ms; user-initiated checks cancel any pending startup check.
  • Behavioral Change: reduceDesktopUpdateStateOnNoUpdate now preserves an optional message in state instead of always nullifying it, affecting how nightly-specific no-update messages are surfaced in the UI.

Macroscope summarized db5c50d.

- Compare stable and nightly feeds to pick the best candidate
- Preserve no-update messages for older nightly builds
- Show available update versions in the settings and sidebar UI
@coderabbitai
Copy link
Copy Markdown

coderabbitai bot commented Apr 17, 2026

Important

Review skipped

Auto reviews are disabled on this repository. Please check the settings in the CodeRabbit UI or the .coderabbit.yaml file in this repository. To trigger a single review, invoke the @coderabbitai review command.

⚙️ Run configuration

Configuration used: Repository UI

Review profile: CHILL

Plan: Pro

Run ID: 9b832fa4-87a4-4bf6-aac1-bf6eb4cceec9

You can disable this status message by setting the reviews.review_status to false in the CodeRabbit configuration file.

Use the checkbox below for a quick retry:

  • 🔍 Trigger review
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

@github-actions github-actions bot added size:L 100-499 changed lines (additions + deletions). vouch:unvouched PR author is not yet trusted in the VOUCHED list. labels Apr 17, 2026
@iPixelGalaxy iPixelGalaxy mentioned this pull request Apr 17, 2026
3 tasks
Comment thread apps/desktop/src/main.ts
@macroscopeapp
Copy link
Copy Markdown
Contributor

macroscopeapp bot commented Apr 17, 2026

Approvability

Verdict: Needs human review

This PR introduces new auto-update behavior (checking both nightly and stable feeds, version comparison logic, UI changes) with significant runtime impact. Additionally, an unresolved high-severity review comment identifies a potential bug where the wrong update version could be downloaded due to provider state tracking issues.

You can customize Macroscope's approvability policy. Learn more.

- Rename the collector field to reflect the checked channel
- Record the last successful channel check and use it when restoring the selected provider
- Remove the stale updater callback assignment
Copy link
Copy Markdown
Contributor

@cursor cursor bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Cursor Bugbot has reviewed your changes and found 1 potential issue.

There are 2 total unresolved issues (including 1 from previous review).

Fix All in Cursor

❌ Bugbot Autofix is OFF. To automatically fix reported issues with cloud agents, enable autofix in the Cursor dashboard.

Reviewed by Cursor Bugbot for commit 601f030. Configure here.

Comment thread apps/web/src/components/settings/SettingsPanels.tsx
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

size:L 100-499 changed lines (additions + deletions). vouch:unvouched PR author is not yet trusted in the VOUCHED list.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant