Skip to content

fix(updates): never announce the version already running - #559

Merged
ibrahimroshdy merged 2 commits into
mainfrom
fix/update-notice-after-upgrade
Nov 14, 2026
Merged

ibrahimroshdy merged 2 commits into
mainfrom
fix/update-notice-after-upgrade

Conversation

@ibrahimroshdy

Copy link
Copy Markdown
Collaborator

After an upgrade, admin pages could still say "Kept 1.14.7 is available — This server runs 1.14.7": a stored update-check answer from before the upgrade outlived it until the next daily check.

Closes #552.

  • Reading: a stored answer is shown only when its release is newer than the running version (readUpdateCheck, which feeds the admin notice and the Status card, and the kept_update_available metric). Right away, before any new check.
  • After an upgrade: each stored answer records the version it was checked against; when the running version differs, the next hourly run asks again instead of waiting for the daily hour. Nothing is asked at boot, and nothing while the check is off.
  • Docs: one sentence in admin/upgrades.md, and the metric's row in admin/observability.md.

Definition of done

  • Tests: four in updates/check.test.ts failed before the fix (same version shows nothing, a newer one still shows, past it shows nothing, a re-check at the next hourly run after an upgrade); a fifth guards "never ask while off". src/updates and src/backup/watch.test.ts 30/30. Fast gate green.
  • Docs: as above.
  • Catalogues: n/a (no new strings).
  • KEPT_* settings: n/a.
  • Security-relevant: no.
  • Roadmap: Update notice shows "1.14.7 is available" on a server that already runs 1.14.7 #552 on 1.14.8.

A stored update-check answer outlived an upgrade: a server upgraded to
the release the last check found said "Kept 1.14.7 is available, this
server runs 1.14.7" until the next daily check.

Every reader now compares the stored release with the running version
again: the status page's updates (the Admin notice and the Updates
card) and the kept_update_available metric show only a newer one. Each
answer now keeps the running version it was asked for, and an answer
for another version (or one stored before this) is due at the next
hourly run instead of waiting for the instance's hour. Nothing is asked
at boot, and nothing at all while the check is off.

Signed-off-by: Ibrahim Roshdy <22573766+ibrahimroshdy@users.noreply.github.com>
@ibrahimroshdy
ibrahimroshdy requested a review from a team as a code owner November 14, 2026 00:03
@ibrahimroshdy ibrahimroshdy added this to the 1.14.8 milestone Nov 14, 2026
@ibrahimroshdy ibrahimroshdy added bug Something doesn't work as it should area: server API, database and jobs (apps/server) labels Nov 14, 2026
Signed-off-by: Ibrahim Roshdy <22573766+ibrahimroshdy@users.noreply.github.com>
@ibrahimroshdy
ibrahimroshdy merged commit 6626581 into main Nov 14, 2026
21 checks passed
@ibrahimroshdy
ibrahimroshdy deleted the fix/update-notice-after-upgrade branch November 14, 2026 00:25
@github-actions github-actions Bot locked and limited conversation to collaborators Nov 14, 2026
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

area: server API, database and jobs (apps/server) bug Something doesn't work as it should

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Update notice shows "1.14.7 is available" on a server that already runs 1.14.7

1 participant