Skip to content

Stop OK Desktop's "Update to X didn't install" notice from firing…#424

Merged
inkeep-oss-sync[bot] merged 1 commit into
mainfrom
copybara/sync
Jul 1, 2026
Merged

Stop OK Desktop's "Update to X didn't install" notice from firing…#424
inkeep-oss-sync[bot] merged 1 commit into
mainfrom
copybara/sync

Conversation

@inkeep-oss-sync

Copy link
Copy Markdown
Contributor

Stop OK Desktop's "Update to X didn't install" notice from firing spuriously and re-appearing on every launch. The boot-time failed-install detector now handles two cases it previously got wrong:

  1. Cross-channel state. The stable and beta builds share one settings file (same app id), so a version that one channel armed as its pending install could poison the other channel's boot check. A beta build would show "Update to 0.23.0 didn't install" for a stable version it can never install (cross-channel updates are blocked), and there was no way for it to clear, so the notice returned on every launch. That stale cross-channel record is now cleared silently.

  2. No retry bound. A genuinely stuck install (a persistently-failing installer, a pulled release) re-surfaced the notice on every boot forever. It is now shown at most 3 times per failed update, after which the record is dropped. The 7-day "updates paused" hint remains the backstop.

Genuine same-channel install failures still surface as before, so a real failed update is not hidden.

…344)

* fix(desktop): stop stale/cross-channel install-failed notice from nagging every boot

The boot-time failed-install detector (PRD-7149) armed attemptedInstall at
download and only cleared it once the running version reached it, with no
channel check and no retry bound. Two failure modes resulted:

- Cross-channel contamination: stable and beta builds share one state.json
  (same appId/productName), so a version armed by one channel poisoned the
  other channel's boot check. A beta build surfaced Update to <stable X>
  didnt install for a version its update-available veto guarantees it can
  never install, and the record never cleared, so the card re-fired every
  boot. Now cleared silently when attemptedInstall and the running build are
  on different channels.
- Unbounded nag: a genuinely stuck install re-surfaced the card every boot
  forever. Now capped at INSTALL_FAILURE_MAX_SURFACES (3) surfacings, after
  which the record is dropped; the 7-day stuck-hint stays the backstop.

Adds attemptedInstallSurfacedCount to AppState (defensively coerced) and the
attempted-install-cross-channel / install-failed-giveup dispatch tags. Genuine
same-channel failures still surface as before.

* address review: clear versionPendingInstall on install abandonment + test hardening

Review (claude bot) flagged that the giveup branch cleared attemptedInstall but
left versionPendingInstall armed. For a higher-MMP attempted version the MMP-only
stale-pending reconciliation cannot clear it, leaving a phantom 'ready to install'
banner (and dedup-blocking a genuine re-download). Fix: the giveup AND the
cross-channel abandonment branches now also clear versionPendingInstall (the
cross-channel branch has the identical latent issue — a stale stable pending
marker on a beta build).

Tests: assert versionPendingInstall is cleared in the giveup + cross-channel
paths (higher-MMP versions so stale-pending does not pre-clear); add persist-
failure tests for both new branches; add a same-version re-download budget-
preserve test; assert the surface counter resets on success reconcile.
GitOrigin-RevId: 32b8aeac91d9ab4a4223d9f2ad288919490e43de

@inkeep-internal-ci inkeep-internal-ci Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Automated approval from agents-private public-mirror-sync (run: https://github.com/inkeep/agents-private/actions/runs/28542403968). Source of truth is the monorepo; direct edits on inkeep/open-knowledge are overwritten on next sync.

@inkeep-oss-sync
inkeep-oss-sync Bot merged commit 86c5118 into main Jul 1, 2026
@inkeep-oss-sync
inkeep-oss-sync Bot deleted the copybara/sync branch July 1, 2026 19:34
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