Studio: stop the llama.cpp update banner flickering and show the download size - #6338
Conversation
There was a problem hiding this comment.
Code Review
This pull request modifies the useLlamaUpdateCheck hook in use-llama-update-check.ts to stop resetting the visible state when the update check is disabled. This change prevents the banner from blinking during transient state flips (such as brief route or authentication changes) while still stopping the progress animation. There are no review comments, so I have no feedback to provide.
Important
The consumer version of Gemini Code Assist on GitHub is being sunset. Starting June 18, 2026, new organization installations will be blocked, and all code review activity will officially cease on July 17, 2026.
For more details on the timeline and next steps, please review the Help Documentation.
…load size The banner animated in and out with a motion opacity + scale + translate transition. That transform/opacity transition promotes a GPU compositing layer whose first and last frame can flash for a moment on real displays, which reads as a flicker on appear and again on dismiss/snooze. Drop the animation and render the banner as a plain conditional mount: it appears and leaves cleanly with nothing to flash. Also surface the download size. update-status now reports the size of the prebuilt that Update would fetch (the latest-release asset matching this host's bundle), and the banner shows it as whole MB next to the no-restart note, so the cost of the update is clear before clicking.
c4682fc to
3aca6f7
Compare
for more information, see https://pre-commit.ci
|
@codex review |
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: b77d40cfb2
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
| return None | ||
| # The platform suffix is tag-independent (e.g. "linux-x64-cuda13-newer.tar.gz"), | ||
| # so derive it from the first platform token rather than stripping the tag. | ||
| m = re.search(r"-((?:linux|windows|macos|darwin)-.*)$", installed_asset) |
There was a problem hiding this comment.
Include upstream asset names in size matching
For upstream installs the marker records asset names like llama-...-bin-ubuntu-x64.tar.gz and llama-...-bin-win-cpu-x64.zip (the installer builds those names in studio/install_llama_prebuilt.py:1463 and studio/install_llama_prebuilt.py:1526), and those installs still surface this update banner. Because this regex only accepts suffixes starting with linux, windows, macos, or darwin, update_download_size_bytes() returns None before checking the latest release assets for those supported paths, so the new size label never appears even though the asset exists. Please include the upstream ubuntu/win forms or derive the lookup from the actual marker asset name.
Useful? React with 👍 / 👎.
| # Size of the prebuilt that Update would download, for the banner. Only when | ||
| # an update is offered; fails open to None (offline / no matching asset). | ||
| update_size_bytes = None | ||
| if update_available: |
There was a problem hiding this comment.
Populate the size for source-build updates
When the active install is markerless but _source_build_status() offers a prebuilt, get_update_status() returns that src response before reaching this new size lookup, and LlamaUpdateStatusResponse then defaults the missing update_size_bytes to null. In that source-build update path the resolver already knows the exact asset that the Update button will fetch, but the banner still omits the download size, so the new size display does not work for a supported update scenario.
Useful? React with 👍 / 👎.
update_download_size_bytes now accepts the upstream ggml-org ubuntu-/win- asset suffixes and falls back to the marker's binary_repo, so the size resolves for CPU/ROCm prebuilts (the fork publish repo only carries the app-* and macOS bundles). The source-build update path now populates update_size_bytes from the resolved asset, matching the marker path. Both fail open to null. Adds regression tests for the upstream and source-build size lookups and the route field round-trip.
|
You have reached your Codex usage limits for code reviews. You can see your limits in the Codex usage dashboard. |
|
Pushed a follow-up (d118bb7) to surface the download size in two cases where it was being skipped:
Both still fail open to |
for more information, see https://pre-commit.ci
|
Codex usage limits have been reached for code reviews. Please check with the admins of this repo to increase the limits by adding credits. |
Problem
The llama.cpp update banner flickered: a brief flash when it appears, and again when dismissing it (X) or snoozing it ("Remind me later").
Cause
The banner animated in and out with a motion
opacity+scale+translatetransition. That transform/opacity transition promotes a GPU compositing layer whose first and last frame can flash for a moment on a real display. It never reproduces headless (the opacity ramps cleanly there), only on actual GPU compositing, which is why it showed up on the desktop/browser but not in automated capture.Fix
Drop the enter/exit animation and render the banner as a plain conditional mount. It now appears and leaves cleanly with no compositing layer to flash, on both appear and dismiss/snooze. Verified frame-by-frame: it renders at
opacity:1, transform:nonefrom the first frame, and on dismiss the node is removed within a frame at steady opacity (no fade ramp).Surface the download size.
GET /api/llama/update-statusnow reportsupdate_size_bytes: the size of the prebuilt that Update would fetch (the latest-release asset matching this host's bundle, e.g.linux-x64-cuda13-newer). The banner shows it as whole MB next to the no-restart note, so the cost of the update is clear before clicking.Notes
null(offline, or no matching asset), consistent with the rest of the freshness module; the banner simply omits the size in that case.tsc -bclean on the frontend; backendtest_llama_cpp_freshness,test_llama_cpp_update, andtest_llama_routeall pass.