Skip to content

Desktop app: update in place, optional development builds (1.14.0) - #167

Merged
Timothysit merged 1 commit into
mainfrom
feature/app-self-update
Oct 23, 2026
Merged

Timothysit merged 1 commit into
mainfrom
feature/app-self-update

Conversation

@Timothysit

Copy link
Copy Markdown
Collaborator

What changes for app users

  • Update to vX in the version window (click the version number in the toolbar). It downloads the new version, closes MEA-NAP, installs it and reopens it, in about a minute. No browser is involved, so there's no Chrome "dangerous download" warning and no Mac "Open Anyway" step. Settings and results are kept.
  • Also offer development builds (a tick box, off by default) offers every merge to main once its apps are built, usually within about half an hour.
  • Users on 1.13.0 need to download this version once by hand. After that, updates happen in the app.

How

  • meanap.updates.check_app picks this computer's file from the release: Windows, Apple-silicon Mac (also when an Intel build runs under Rosetta) or Intel Mac. With development builds ticked, it also considers dev pre-releases that already have that file attached.
  • New module meanap.app_update:
    • Download: checks the file's size and GitHub's SHA-256, and supports cancelling.
    • Install:
      • Windows runs the installer with /SILENT /RELAUNCH=1. meanap.iss has a new [Run] entry for that relaunch.
      • Mac runs a shell script that waits for the app to quit, copies the new .app out of the .dmg, swaps it in with two renames, and reopens it. If anything fails it puts the old app back.
    • Report: the next start says how the update went, using pending-update.json.
  • Falls back to the download page when the Mac app is running from Downloads or the .dmg (translocated) or its folder isn't writable, or when the release's files aren't built yet.
  • CI:
    • dev-build.yml calls desktop-app.yml (now workflow_call) to attach apps to each dev pre-release.
    • It deletes the app files from all but the newest 5 dev builds; the tags and notes stay.
    • The tagging concurrency moved to the tag job, so the about 20-minute app builds don't delay the next merge's tag.

Tests

  • python/test_desktop_app.py: 27 tests, all passing. They cover:
    • which release and file the check picks;
    • download size and checksum checks, and cancelling;
    • the Mac script run for real, with stand-ins for hdiutil, ditto and open, in both the success and the put-back-on-failure case;
    • the Windows installer arguments;
    • the startup report;
    • the dialog buttons.
  • Not yet tried on a real Windows PC or Mac. First real test: install 1.14.0 by hand, tick development builds, then update to the next dev build.

🤖 Generated with Claude Code

https://claude.ai/code/session_01X78uDckMcD2xCkAo9Hj7g8

… (1.14.0)

"Update to vX" in the app's version window downloads this computer's file
(size and SHA-256 checked), quits, and hands over: the Windows installer runs
silently and reopens the app (/RELAUNCH=1 in meanap.iss); on a Mac a shell
script swaps the .app in Applications and reopens it, putting the old one back
if anything fails. The next start reports how it went. Fetched by the app
rather than a browser, the file carries no download mark, so no Chrome or
Gatekeeper warning. Falls back to the download page where it can't (Mac app
not in Applications, folder not writable, files not built yet).

"Also offer development builds" adds the per-merge pre-releases: dev-build.yml
now calls desktop-app.yml to attach apps to each one, and removes the apps of
all but the newest five dev builds.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01X78uDckMcD2xCkAo9Hj7g8
@Timothysit
Timothysit merged commit 80a7bb0 into main Oct 23, 2026
3 of 6 checks passed
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