Skip to content

Update check and Download: the newest release on GitHub - #506

Merged
bonninr merged 2 commits into
mainfrom
fix/update-check-github
Oct 21, 2026
Merged

bonninr merged 2 commits into
mainfrom
fix/update-check-github

Conversation

@bonninr

@bonninr bonninr commented Oct 21, 2026 •

Copy link
Copy Markdown
Owner

The once-a-day update check reads GitHub's record of the newest release, https://api.github.com/repos/bonninr/masterpiece/releases/latest, and takes the version from its tag (v0.9.0 gives 0.9.0). Drafts and pre-releases are left out of "latest" by GitHub.

  • Requests carry User-Agent: Masterpiece and Accept: application/vnd.github+json, on Windows and macOS through JUCE and on Linux through curl.
  • A plain number is still read as it is, so MASTERPIECE_UPDATE_URL keeps working with a test server or a copy.
  • Once a day per player sits well inside GitHub's allowance of 60 requests an hour for a request with no account.
  • The notice's Download button opens https://github.com/bonninr/masterpiece/releases/latest, the newest release's page with its downloads.
  • The setting's tooltip in General settings, Log says the number comes from GitHub, in all eight languages.
  • version.txt on the site stays: 0.8.1 and earlier read it.

functional.settings.update-check checks the tag, a plain number, and that a portal's page, a rate-limit refusal and a tag that is not a version give nothing.

Checked in the program on Windows:

Run Log Window
api.github.com update check: this is the newest, 0.8.1 no notice
local copy of the record tagged v0.9.0 update check: 0.9.0 is out, this is 0.8.1 "Masterpiece 0.9.0 is out", Download, Never check again
Download clicked in that notice the browser opens "Release Masterpiece v0.8.1 · bonninr/masterpiece · GitHub"

The once-a-day check reads GitHub's record of the newest release from
api.github.com and takes the version from its tag. A plain number is
still read as it is, for MASTERPIECE_UPDATE_URL. The site's version.txt
stays for the versions already out.
The notice's Download button opens the newest release's page on GitHub,
with its downloads. The setting's tooltip says the number comes from
GitHub, in all eight languages.
@bonninr bonninr changed the title Update check: reads the newest release from GitHub Update check and Download: the newest release on GitHub Oct 21, 2026
@bonninr
bonninr merged commit 88b0412 into main Oct 21, 2026
10 checks passed
@bonninr
bonninr deleted the fix/update-check-github branch October 21, 2026 22:50
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.

2 participants