Skip to content

Updates: the updater reports installing, ready, installed and failed, and installs at exit - #1980

Merged
dylanmtaylor merged 2 commits into
storytold:mainfrom
dotCooCoo:chore/craft-update-updater-fixes
Nov 9, 2026
Merged

dylanmtaylor merged 2 commits into
storytold:mainfrom
dotCooCoo:chore/craft-update-updater-fixes

Conversation

@dotCooCoo

Copy link
Copy Markdown
Contributor

Draft until storytold/craft-libs#687 and #696 merge. The craft-libs pin points at dotCooCoo/craft-libs c7c84230, a branch that is craft-libs main at 0a9d1f48 with #687 and then #696 merged in. When both merge, the pin moves to the craft-libs merge commit on storytold/craft-libs and the pull request is marked ready.

What changes

  • Cargo.toml: craft-media, craft-pdf, craft-update, craft-ui and the krilla patch move together from c5a1cbfb to c7c84230. Cargo.lock changes those entries and craft-i18n and craft-fonts-build, and drops zopfli from zip's dependencies. The web app's craft-web-api and craft-web-host stay on their own rev.
  • crates/ui-egui/src/dialogs/updates_ui.rs: the check result window now shows whenever the updater's status is not idle, not only after Help ▸ Check for Updates. At the first start after an update it says that the update installed (Status::Updated) or why it failed (Status::InstallFailed). OK dismisses it, Check Again runs a new check, and Restart to Update (Status::Ready) calls Updater::restart_to_update, so the next frame asks the window to close once nothing is unsaved. The new Installing, Ready and Managed statuses are shown by the same window.
  • apps/deckcraft/src/main.rs, crates/ui-egui/src/app.rs: on_exit calls the new SlideApp::start_pending_update, which calls Updater::start_pending_update. On Windows the install helper now starts at the app's exit instead of right after the download, so a canceled close keeps the update ready. On macOS on_exit ends the process before the app is dropped, so the updater's own drop would not run there.
  • New tests the_start_after_an_update_reports_it_until_dismissed and the_start_after_a_failed_update_reports_why_and_offers_a_new_check: an outcome record written under a temporary folder makes the start show the result window, OK returns the status to idle, and Check Again requests a check. Both fail when the window's answers are ignored.

No other source change was needed for the newer craft-libs crates.

Other craft-libs changes since c5a1cbfb

Overlap

No open pull request moves the craft-libs pin. #1488, #1530, #1549 and #1571 add craft-i18n at c5a1cbfb, the same rev as craft-ui, and #1540 adds it at 92d392cf; whichever merges second needs only the rev in Cargo.toml and Cargo.lock. Earlier pin changes landed together with the change that needed them (#1253, #1377, #1383, #1386, #1457, #1561, #1562), and 9678ed7d moved the pin in a direct commit.

Tested

On Windows 11, on 48e22031 plus this commit, without craft-fonts:

  • cargo fmt --all -- --check: clean.
  • cargo check --workspace --tests --locked: clean.
  • cargo clippy --locked --all-targets -- -D warnings for the 16 crates that depend on craft-libs crates: clean.
  • cargo test --locked --no-fail-fast for the same 16 crates: 23 test binaries and 13 doc-test runs, 1570 passed, 0 failed, 6 ignored.
  • cargo xtask assets: all 48 asset files attributed. cargo xtask layers: 28 crates, no layering violations.

… and installs at exit

craft-media, craft-pdf, craft-ui, craft-update and krilla move from craft-libs
c5a1cbfb to c7c84230, which carries storytold/craft-libs#687 and storytold#696.

The check result window now shows whenever the updater's status is not
idle: after Help > Check for Updates, and at the first start after an
update, to say that it installed or why it failed. Restart to Update in
that window asks the app to close once nothing is unsaved. on_exit starts
the helper of a ready update, since on macOS it ends the process before
the app is dropped.
@coderabbitai

coderabbitai Bot commented Nov 8, 2026 •

Copy link
Copy Markdown
Contributor

Explain Change →

Caution

Review failed

The pull request is closed.

  • Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

Share

…s pin

The pdf-deps check compared craft-pdf and krilla against storytold/craft-libs
at c5a1cbfb, so the gate stopped at that step once the pin moved to
dotCooCoo/craft-libs c7c84230. The expected repository and revision now
match the pin in Cargo.toml.
@dotCooCoo

Copy link
Copy Markdown
Contributor Author

The gate stopped at cargo xtask pdf-deps: the check still expected craft-pdf and krilla from storytold/craft-libs at c5a1cbfb, while this branch pins them to dotCooCoo/craft-libs at c7c84230.

3504a9d sets the expected repository and revision in xtask/src/pdf_deps.rs to the pin in Cargo.toml. When the pin moves to the craft-libs merge commit, the same two constants move with it. Locally, cargo xtask pdf-deps passes, cargo test -p xtask passes 29 tests, and cargo check --workspace --tests --locked is clean. The branch has no conflicts with main.

@aiongg aiongg added missing feature The reference application has it and we do not, or only part of it security needs decision Needs a product or scope decision by a maintainer labels Nov 8, 2026

@dylanmtaylor dylanmtaylor 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.

LGTM. craft-libs#696 is merged into main.

@dylanmtaylor
dylanmtaylor marked this pull request as ready for review November 9, 2026 03:12
@dylanmtaylor
dylanmtaylor merged commit 61423ea into storytold:main Nov 9, 2026
8 checks passed
filforce95 added a commit to filforce95/deckcraft that referenced this pull request Nov 9, 2026
Conflict: main moved the craft-libs pin from c5a1cbfb to 1b34eba4 (storytold#1980,
5ee82b4). craft-i18n moves with it, so it stays on the same rev as
craft-ui; crates/i18n is unchanged between the two revs.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

missing feature The reference application has it and we do not, or only part of it needs decision Needs a product or scope decision by a maintainer security

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants