Skip to content

feat: show image created dates and versions in updates - #4665

Merged
kmendell merged 4 commits into
mainfrom
feat/version-update-logic
Nov 6, 2026
Merged

kmendell merged 4 commits into
mainfrom
feat/version-update-logic

Conversation

@kmendell

@kmendell kmendell commented Nov 6, 2026 •

Copy link
Copy Markdown
Member

Checklist

  • This PR is not opened from my fork's main branch
  • All new user-facing strings are translated via Paraglide (m.*())

What This PR Implements

Rolling tags such as :latest reported updates as digest pairs (sha256:8978d2f5 → sha256:3eb277ac), which doesn't show what changed. When a digest update is found, Arcane now reads the new image's org.opencontainers.image.version label and its created date, and shows a version change such as 2.3.6 → 2.3.7 with a build date. Images without the label keep the digest display.

The digest comparison still decides HasUpdate. The tag-policy path is unchanged.

Fixes:

Addresses discussion #4266

Changes Made

  • Registry: ImageLabels is now ImageConfig, which returns the full config (labels and created date). The cache stores configs. All callers are updated. The lookup accepts the update check's registry credentials. Release notes and self-upgrade lookups pass none, as before.
  • Local snapshot: reads the version label and created time from the inspect response already fetched. No extra call.
  • Update check: when an update is found, fetches the remote config for the new digest once. Failures are logged and the result stays digest-only. Sets LatestVersion, CurrentVersion, LatestCreated, and CurrentCreated.
  • Persistence: migration 00105_add_image_update_created adds current_created and latest_created, with a down migration. A saved LatestVersion and LatestCreated carry over only when the latest digest is unchanged. The project container merge drops LatestCreated when the latest version, digest, or update type changes.
  • API types: CurrentCreated and LatestCreated on ImageUpdateResponse and ImageUpdateInfo, mirrored in the TypeScript types.
  • UI: update rows and the update popover show versions and the build date, with the digest as secondary text. The popover title reads "Version Update" only when the version changed. New string keys are in frontend/messages/en.json.
  • Notifications, email, CLI: prefer versions and fall back to short digests. Email keeps the digest rows and adds version rows when present.

Testing Done

  • just format all then just lint all: exit 0, 0 issues. After removing comments from types/, format and lint were re-run on types/ only: 0 issues.
  • svelte-check: 817 files, 0 errors.
  • Go tests pass for imageupdate (and its children), registry, version, project, database, notification, pkg/notifications, and the CLI's pkg/images/updates.
  • New tests cover:
    • A remote version label resolved against an in-process registry.
    • A missing label or failed config fetch leaving a digest-only result with no error.
    • A saved version carried over only for the same digest.
    • Migration 105 up and down.
  • Not verified: the app was not run against a live stack, so the UI and notification output have not been viewed.

AI Tool Used (if applicable)

N/A

Additional Context

  • Registry logins stored only in the Docker daemon are not used for the version and date lookup. Private images that rely only on those credentials show digests and log a warning.
  • Each new digest on an image with an update costs one manifest fetch and one config fetch, cached per digest. Up-to-date images cost nothing extra. Docker Hub rate limits apply.
  • A few older tests in imageupdate fake the digest lookup but now make one real config fetch. The fetch fails and the tests still pass, but they need network access.

Disclaimer Greptiles Reviews use AI, make sure to check over its work.

To better help train Greptile on our codebase, if the comment is useful and valid Like the comment, if its not helpful or invalid Dislike

To have Greptile Re-Review the changes, mention greptileai.

RetriggerView in GreptileConfidence Score: 5/5

The PR appears safe to merge; the missing version details in normal update emails are now included.

Summary

Adds image versions and build dates to update details while keeping digest checks responsible for finding updates.

  • Image updates now include available versions and build dates.
  • Image update rows show versions and build dates beside digests.
  • Update notices and the CLI show versions when they are available.

Reviews (4) · Last reviewed commit: "feat: show version transitions in batch ..." · Reviewed by Greptile

@kmendell
kmendell requested a review from a team November 6, 2026 00:11
Comment thread backend/internal/imageupdate/service.go Resolved
Comment thread backend/internal/imageupdate/service.go Resolved
Comment thread backend/internal/imageupdate/service.go Resolved
Comment thread frontend/src/lib/utils/image-updates.ts Resolved
Comment thread backend/pkg/notifications/messages.go Resolved
Comment thread backend/internal/imageupdate/service.go Resolved
- Store current and latest image created timestamps on image updates (migration 105)
- Resolve the latest version label and created date from the remote image config on digest updates
- Carry latest version and created date forward only when the digest is unchanged
- Include current and latest versions in image update notification emails
- Fetch remote image configs for the local image's platform, not linux/GOARCH only
- Keep current and latest created dates and versions when a check fails or after a pull
- Clear stale update flags when the latest digest is unchanged
- Escape HTML and Slack code spans and strip backticks in Markdown notifications
- Show a version change only when the latest version differs from the current one
greptile-apps[bot]
greptile-apps Bot previously approved these changes Nov 6, 2026
@kmendell
kmendell force-pushed the feat/version-update-logic branch from 5a154be to fb83dbd Compare November 6, 2026 00:37
@greptile-apps
greptile-apps Bot dismissed their stale review November 6, 2026 00:37

Dismissed because a newer commit was pushed; Greptile will re-review the current head.

- Render current and latest versions in ntfy transitions via formatNotificationCode
- Replace hardcoded backticks in writeNtfyTransition
greptile-apps[bot]
greptile-apps Bot previously approved these changes Nov 6, 2026
- Batch image update emails now show `type: current → latest` per image, or the update type alone when no versions are known.
- Export `UpdateVersions` from `pkg/notifications` so the email template and message builders share one version resolver.
@greptile-apps
greptile-apps Bot dismissed their stale review November 6, 2026 01:02

Dismissed because a newer commit was pushed; Greptile will re-review the current head.

@kmendell
kmendell merged commit 163f854 into main Nov 6, 2026
21 checks passed
@kmendell
kmendell deleted the feat/version-update-logic branch November 6, 2026 01:08
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant