Repository navigation
fix(update): remember a failed update and skip a refused version - #348
Conversation
A failed download, a refused install or an unreachable helper is kept in Settings > Updates with its date and message. A refused or unreachable automatic update is not downloaded again by the daily check. The record is hidden once a download finishes, an install succeeds or a build at least as new as the version runs.
Codex Review Summary: ✅ CompletedThis comment shows the latest Codex review activity on this pull request.
ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings. |
The identifier was applied to both texts, so the Settings UI check found two matches. Also move the README sentence behind the paragraph's description of automatic updates.
… changes Sparkle reports the change through KVO, the fake did not, so the manual Settings UI check stopped before the new update problem assertions.
Orchestrator review: acceptedOn
Own checks: Rendered the new row for an unreachable helper, a refused version, a failed download and a long message, in light and dark. Ran checkUpdateSettings in a real window (moved to the start of the suite for that run): PASS update settings layout. Two defects found and fixed here: the README sentence separated the automatic-update toggle from its explanation, and the settings.updates.problem identifier was on both texts (c2fafc1). The fake updater did not notify the view, so the check stopped before the new assertions, on main too (d9c2736). Deviations: Accepted: the store tests cover a new API and cannot fail on the old code; the repeated download was shown failing with the skip rule removed. Open for the user:
|
Summary
Fixes #342
Acceptance
bash macOS/scripts/test.sh settings: pass (exit 0, 10PASS updatelines, includingupdate problem storeandupdate failures).Failing first on the old code: before the behaviour was added, the first new expectation failed:
FAIL .../UpdateTests.swift:131 A failed automatic download is remembered and retried: nil.Repeated download, with the skip rule temporarily removed (restored afterwards):
FAIL .../UpdateTests.swift:161 The version that the helper did not install is not downloaded again: ["updateDownload:begin", "updateDownload:failed", ..., "updateInstall:failed", "updateDownload:begin"]bash macOS/scripts/test.sh updater: pass (PASS updater: verification order, ownership, refusals, sessions, lifetime,PASS 1 units: updater).bash macOS/scripts/build.sh: pass (exit 0).build_swift_test settings-ui-tests build/settings-ui-tests: compiled (exit 0). The harness was not run.docs-lint.py,comment-lint.py --base origin/main,style-lint.py --base origin/main: all pass (exit 0). style-lint first flagged three long lines; fixed in the same commit.git status --porcelain: empty after commit.Deviations and open issues
settings.updates.problemandsettings.updates.packagechecks are therefore unverified on screen.IFUpdaterAccesssettings view section is untested visually; the date string12月4日更新失败comes fromDate.FormatStylewith localezh_Hansand was not checked in a rendered window.test.sh settingsrun leftbuild/artifacts, all inside the worktree and not committed.Delivery record