Repository navigation
Add a beta release channel with an in-app opt-in and pre-migration DB snapshots - #28
Merged
Merged
Conversation
Deploying opentradeoss with
|
| Latest commit: |
755ab7d
|
| Status: | ✅ Deploy successful! |
| Preview URL: | https://59284473.opentradeoss.pages.dev |
| Branch Preview URL: | https://feat-beta-release-channel.opentradeoss.pages.dev |
… snapshots Release workflow: a tag of the form vX.Y.Z-beta.N builds with the version taken from the tag (-c.extraMetadata.version) instead of app/package.json, and once the sourcemaps are attached the GitHub release is flagged as a pre-release and published. GitHub excludes pre-releases from /releases/latest, which is what electron-updater resolves for stable installs and what the download permalink serves, so beta builds stay off the stable channel. Stable tags gain two guards: the tag must match the committed version, and the release must not be flagged as a pre-release. Only the beta identifier is accepted, since it is the one electron-updater treats as a channel that graduates to stable, and version numbers must be strict semver (no leading zeros) so the updater can parse them. App: a new updateChannel setting (stable | beta) is shown in Settings → About as "Receive beta updates". The host sets it to beta when the running version changes to a prerelease, so installing a beta build enrolls the install; it stays set until the user turns it off. The launcher forwards the setting to the updater, which maps it onto allowPrerelease. The boot update check now runs from the first settings push (or immediately with the build's default if the host failed to start) so it always uses the chosen channel, and the switch is disabled while a check or download is in flight. Turning beta off on a beta build leaves the install on its current version until the next stable release, since downgrades are refused. Database: before an existing database is upgraded, createDb() writes a VACUUM INTO snapshot to <home>/backups/ so an older build's schema can be restored by hand. Snapshots are best-effort, logged to the host log, taken at most once per source schema version, and never pruned.
Automage
force-pushed
the
feat/beta-release-channel
branch
from
September 15, 2026 21:11
a8ffa68 to
755ab7d
Compare
Merged
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Adds a beta release channel on top of the existing GitHub Releases pipeline, an in-app opt-in for it, and pre-migration snapshots of the app database.
Release workflow (
.github/workflows/release-desktop.yml)vX.Y.Z-beta.Nbuilds with the version taken from the tag (-c.extraMetadata.version) instead ofapp/package.json, so a beta can be cut from any commit without a version-bump commit./releases/latest, which is what electron-updater resolves for stable installs and what the download permalink serves, so beta builds never reach the stable channel. electron-builder does not set this flag from the version string on its own.app/package.jsonversion, and the release must not be flagged as a pre-release.betaprerelease identifier is accepted. It is the one electron-updater treats as a channel that graduates to stable; other identifiers would never be offered the stable release.App
updateChannelsetting (stable | beta), shown in Settings → About as Receive beta updates.betawhen the running version changes to a prerelease, so installing a beta build enrolls the install. It stays set until the user turns it off.allowPrerelease. The boot update check now runs from the first settings push (or immediately with the build's default if the host failed to start), so it always uses the chosen channel. The switch is disabled while a check or download is in flight.Database
createDb()writes aVACUUM INTOsnapshot to<home>/backups/app.db.<utc-stamp>.v<from>.bak. This gives a build with an older schema a file to restore by hand, sincemigrate()refuses a database stamped newer than the build.Verification
bun test app/src: 425 pass, 0 failbun run --cwd app typecheck: cleanbunx @biomejs/biome checkon all touched files: cleanbun run --cwd app build: succeedsv0.2.8,v0.2.8-beta.1,v0.2.8-beta.12(accepted) andv0.2.8-rc.1,v0.2.8-beta,v0.2.8-alpha.1(rejected).latest-mac.ymlfallback,extraMetadatamerge, release-type defaulting) was verified against the installed library sources.No beta has been cut with this workflow yet; the first
vX.Y.Z-beta.1tag after merge is the live test.