Skip to content

distribution: download-update progress reporting - #219

Merged
turinglambdaai merged 5 commits into
mainfrom
distribution-download-progress
Oct 13, 2026
Merged

turinglambdaai merged 5 commits into
mainfrom
distribution-download-progress

Conversation

@turinglambdaai

@turinglambdaai turinglambdaai commented Oct 12, 2026 •

Copy link
Copy Markdown
Owner

Extracted from shipped app updaters: downstream applications duplicated download-update solely to drive progress bars, and those copies drifted on redirect and key-handling fixes.

This PR keeps the low-level copy helper private and adds the actual public contract needed by apps: download-update #:on-progress. It reports cumulative bytes from zero through the final signed size, throttles intermediate callbacks, validates callback arity, rejects response bytes beyond the signed artifact size before writing them, and removes .partial files for both ordinary failures and cancellation (�xn:break).

The original test was strengthened so a payload spans multiple 64 KiB reads and proves the exact monotonic cadence; a separate regression proves cancellation cleanup.

Documentation now states callback thread/verification semantics.

Local evidence: focused distribution/public API/docs tests pass.

turinglambdaai and others added 5 commits October 13, 2026 00:33
copy-limited! (now exported) takes #:on-progress and #:progress-every —
byte-count callbacks throttled so fast links do not flood UI pollers —
and download-update threads them through, reporting against the signed
artifact size so a progress bar reads real percentages.

Every tray-era app (fulcrum, movebit) hand-rolled a byte-for-byte copy
of this function just to drive a progress bar, because the first-party
downloader was silent. The duplicated copies had already drifted on the
redirect-following fix (#153) once.
@turinglambdaai
turinglambdaai merged commit 18ab89c into main Oct 13, 2026
23 checks passed
@turinglambdaai
turinglambdaai deleted the distribution-download-progress branch October 13, 2026 00:26
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