A failed check wiped a candidate whose artifact was already verified, a
prefetch that could not start left the user with no way to skip, and
refusing an install closed the notification and the poll, so the update
disappeared until the next start. Keep the candidate on a failed check,
offer the dialog for a flavour that installs from the browser, and let a
refused install leave the notification and the poll in place.
The prefetch and the install helper shared one handoff file, so either
could consume or delete the other's job; the pending record was shared
between installs. Key both per install and per job, and leave the log to
accumulate across runs instead of truncating it at every start.
The helper held the install lock while it started the new build, whose
own startup could not then settle the records. Release it before the
launch. A launch that failed after a good install no longer rolls the
install back or deletes its record, a cancel before the swap reports a
cancel rather than a failure, and closing the completed helper window no
longer frees the widgets under the queued completion.
Cap the download at the size the release announces, so a redirected body
cannot fill the disk before the digest check.
A stale digest from a downgraded build hid every newer release; trust it
only while the release is not newer, except on Nightly, whose version is
its release timestamp. A JSON integer above INT64_MAX no longer throws.
Check the fresh-install rename instead of the resulting folder, which an
existing executable satisfies; pass the signing shell and script as
separate defines so a path with spaces survives; fall back to the
CMakeCache pin when the signing stamp is compared without the ORCA_
variables set.
The updater installed a prefetched build when the application quit, so an
update happened with no click and no visible moment. Now the startup check
only prefetches, a persistent notification opens the dialog once the helper
has verified the artifact, and the dialog's install button is the only path
to the helper. Install-at-quit and the helper's --install-only mode are gone.
Readiness is the helper's verified marker bound to the artifact digest, not
the file name: the helper renames before verifying, and a nightly reuses one
asset name. Skip deletes the cached artifact under a per-download lock.
Installing an update while the automatic prefetch was still writing the same
.part resumed it in a second process, so the digest failed, and Windows could
not even extract the helper. The manual path now waits for a download this run
started, a complete .part is taken as done, and a helper folder that is busy is
reused instead of deleted.
A release build could ship without the publisher or team id it pins, and the
helper would then accept anything the OS trusts. Configure fails for a release
build without the pin its platform needs, and the macOS package compares what
the helper was built with against the pins it ships under.
The Windows installer deleted the old tree before it wrote the new one, so a
failure left no application and no way to report it. It stages the whole tree
beside the target, verifies it, and swaps it in, reporting 1 for a missing
token, 2 for nothing written and 3 for a tree removed but not replaced. Before
handing a tree to an elevated installer the helper requires that it resolve to
the recorded path, carry no reparse point, and hold an uninstaller signed by the
pinned publisher.
The installed channel is keyed by install root like the digest, and a build
installed by hand infers its channel from its version, so a channel switch no
longer needs a previous in-app install. An inferred switch never takes a
candidate that sorts lower: a hand-installed 2.6.0-rc1 is no longer replaced by
an older stable at quit with nothing shown.
Downloads, the extracted helper and the handoff are per install, so two copies
sharing one cache stop deleting each other's artifact and overwriting each
other's job. A download whose bytes are wrong is dropped; one that cannot be read
is set aside rather than failing every start.
A declined dialog disarms the quit-time install, a check that finds nothing
clears the candidate, and flavours that cannot install in place are told about a
release instead of being ignored. A macOS swap exchanges the bundle in one step
where the filesystem allows it, and a cleanup this user cannot perform is logged
instead of retried forever.
The background check no longer opens the update dialog. What to do with a
candidate is a pure decision now (update_action), so it can be tested: an
automatic check prefetches, a check the user started keeps its dialog and
installs at once, and a skipped version stays quiet unless the user asked.
The helper downloads while the application runs and exits; a second run at
quit installs from the verified file. Prefetch therefore takes no lock and
installs nothing, so it cannot race the run that follows it, and the install
that runs after a quit does not start the application again. A failure leaves
update_failed.txt, which the next start shows as a notification: an update
that asks nothing has no other way to report itself. The artifact a prefetch
left behind is now kept by prepare_download_dir instead of being swept and
downloaded again.
The Windows installer is no longer CPack's. CPack hardcodes
RequestExecutionLevel admin and installs to Program Files, so every update
needed a UAC prompt. packaging/windows/orca-slicer.nsi requests the user's
own level and picks the scope at start: a machine-wide install recorded in
the HKLM uninstall key is replaced under Program Files by the elevated helper
it already runs as, and a fresh install goes to LOCALAPPDATA, where an update
needs no elevation at all. The helper now decides that elevation by probing
the install root, and only asks for it when the tree is not writable. Both
registry views are checked, because installers built before this were 32-bit.
A failed install now sets an error level: a silent update reads the exit code,
and an Abort without one looked like success.
is_release_download_url was a prefix test, so a URL with ../ segments
passed it and curl collapsed them into another repository's path. It now
takes the asset name and accepts only <prefix><tag>/<asset_name> made of
plain characters, and the downloader sets CURLOPT_PATH_AS_IS.
The install lock took over a stale pid file with a read, a remove and a
create, so two takers could both win, and the file existed empty before
the pid was written. It now holds flock/LockFileEx on an open handle for
the life of the process; the OS drops it when the holder exits.
On Windows the helper waited only for the parent process. A second
OrcaSlicer running from the install folder kept files locked, and the
silent NSIS installer uninstalled first and then failed. The helper now
waits up to 30 s for such processes and refuses before anything changes.
A nightly installed by hand has no recorded digest and was compared with
the release's updated_at, which follows the last asset upload, so it was
offered itself on every check. The release now has to be more than six
hours newer than the build.
The update dialog was destroyed twice when the updater failed to start:
it lived on the stack while the main frame, its parent, was deleted.
It is now scoped before the install starts.
The install record names the install it belongs to, and only that copy
consumes it. It is read first and deleted after the install lock is
taken, so a held lock no longer leaves the download in the cache.
On macOS a user who cannot write the target's parent folder had no way
to stage the new bundle. It is staged in the cache and copied in by the
single administrator step.
Only the Windows installer and the macOS bundle are replaced in-app now.
A Windows portable zip and a Linux AppImage open their matching release
asset in the browser, and a Flatpak build opens its Flathub page.
WindowsPortable and LinuxAppImage stay as flavours so the right asset is
picked, and is_download_only() marks them. They no longer count as
in-app installs, so the dialog shows "Download" for them.
Removed with the in-app path: the AppImage swap (apply_linux.cpp), the
portable branch of apply_windows.cpp, the portable data_dir recovery and
PendingInstall::data_aside, the per-install cache suffix, the AppImage
environment scrub, the helper in the AppImage and its rpath, and
leave_install_folder(). The helper target is built on Windows and macOS
only.
The tests use the Windows installer as the in-app flavour, and cover the
portable zip, the AppImage with its _belt exclusion, and is_download_only().
The helper exited before reading its handoff because wx's command-line
parser rejected --handoff. Windows portable updates failed on tar.exe
lookup, a working directory inside the install, and the nightly zip's
top-level folder. The AppImage helper now ships with its own libraries.
- Restrict downloads to https GitHub release URLs, verify TLS on the
version check, set CA certificates and FAILONERROR in the downloader.
- Rename the verified download to its asset name, hold it open on
Windows, and relaunch the app when an update fails before the swap.
- Use nowide paths in the helper for non-ASCII Windows user names.
- Roll back by renaming the new tree aside; stage Linux copies beside
the target; drop the predictable macOS marker file.
- Require $APPDIR for AppImage detection; reject read-only macOS volumes.
- Check for updates once after Preferences closes, and drop stale results.
- Offer releases without a matching asset, key Nightly skips by version,
and let Pre-Release offer a newer final release.
- Find pending.json from a .backup copy and keep the backup unless the
new build is running from the target.
- Move the build timestamp into its own generated header so it no
longer invalidates ccache on every CI run.
A third channel resolves to the newest entry the service marks as a
prerelease, and never offers a final release: graduating to one means
switching to Stable. Nightly stays out of it because its tag is not
semver.
Switching to Pre-Release does not take the channel-switch shortcut the
other two targets use; that shortcut could only ever hand back something
older than what is running. Changing channel in Preferences also clears
both skip values, since a skip names a version rather than a channel and
must not silence the channel the user moved to.
The dialog, the helper window and the Preferences dropdown name the
channel, and the asset version match is case-insensitive because the
v2.3.2-rc release spelled its assets V2.3.2-RC.
An executable inside a CMake build tree now resolves to
InstallFlavour::Other on macOS and Windows, so a development build is
never offered an in-app update that would replace the tree it runs from.