Skip to content

fix(personal): releases can no longer downgrade a Mac - #49

Merged
r4iju merged 685 commits into
mainfrom
fix/release-regression
Oct 16, 2026
Merged

r4iju merged 685 commits into
mainfrom
fix/release-regression

Conversation

@r4iju

@r4iju r4iju commented Oct 16, 2026

Copy link
Copy Markdown
Owner

Why
desktop-v0.0.63 shipped from sync/upstream-rebase-20261014, which never merged. The next nightly built main, which was about 660 upstream commits older, and installed it as 0.0.64. That build didn't know migrations 59-64 or the granular auth scopes. Every session that 0.0.63 had stored failed to decode, so every bearer token got 401 invalid_credential, including the Temporal workers' token on the work laptop.

What changes

  • Main moves to the rebase line. This branch starts from the 0.0.63 commit and records main as merged with -s ours. feat(server): optionally retry Codex capacity errors with backoff #47 and the mobile copy fix are already in the rebase. feat(server): disable PostHog telemetry by default #48 is cherry-picked. Main's Oct 8 sync merge had resolved two native background-connection fixes into its conflict resolution, so those are ported verbatim with their test. feat(server): agents can settle their own thread after the run ends #46 settle_after_run is dropped because upstream now defers settle on the calling thread until the turn ends.
  • Builds only move forward along main. t3-alpha-build refuses a commit that isn't on origin/main or doesn't contain the latest desktop-v* tag. It also refuses an explicit version that isn't newer than that tag.
  • Installs never go behind the database. The build stamps its last migration id into the signed app. t3-alpha-install refuses a build that knows fewer migrations than the Mac's statev2.sqlite. It also skips the automatic rollback when a failed build has already migrated the database.

How I verified it

  • Replayed the guard against real history. It refuses the Oct 14 hand build and the Oct 15 nightly, and allows the next build from this branch.
  • Checked the version rule: 0.0.65 and 0.1.0 pass, while 0.0.64 and 0.0.63 are refused after 0.0.64. Checked the migration id helper on a fixture database, a missing database, and studio's real one (64).
  • vp test run apps/server/src/telemetry/AnalyticsService.test.ts: 6/6. apps/server typecheck is clean.
  • The ported native files match main byte for byte. I didn't run the Robolectric test.
  • After merge: build 0.0.65 from main, install it on the work laptop, check that the existing worker token still authenticates, and check that an old zip is refused.

Risk

  • Merge with a merge commit, not a squash. Squashing drops the 0.0.63 commit from main's ancestry, and the guard would then refuse every build.
  • Zips built before this change carry no migration stamp, so the installer refuses them.
  • Upstream's deferred settle still settles if the user pins or unsettles the thread during that turn. feat(server): agents can settle their own thread after the run ends #46 cancelled in that case.
  • A scheduled task prompt that calls settle_after_run must switch to settle.

🤖 Generated with Claude Code

juliusmarminge and others added 30 commits October 11, 2026 10:35
…17050)

Co-authored-by: Julius Marminge <julius0216@outlook.com>
…#17027)

Co-authored-by: Julius Marminge <julius0216@outlook.com>
Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com>
Co-authored-by: t3-code[bot] <269035359+t3-code[bot]@users.noreply.github.com>
Co-authored-by: maria-rcks <254055478+maria-rcks@users.noreply.github.com>
…gg#18352)

Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com>
…dotgg#16271)

Co-authored-by: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
Co-authored-by: Julius Marminge <julius0216@outlook.com>
…pingdotgg#18353)

Co-authored-by: Theo Browne <me@t3.gg>
Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com>
t3dotgg and others added 27 commits October 14, 2026 04:47
…w markup (pingdotgg#19401)

Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com>
…sshd (pingdotgg#19402)

Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com>
…offers a relink (pingdotgg#19379)

Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com>
…ds (pingdotgg#19399)

Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com>
Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com>
…s at the same time (pingdotgg#19411)

Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com>
…vent loop (pingdotgg#19430)

Co-authored-by: Aaron Queen <bompus@users.noreply.github.com>
Co-authored-by: Daniyal <115576848+daniyal-sh@users.noreply.github.com>
Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com>
…d silently (pingdotgg#19417)

Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com>
…otgg#19429)

Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com>
…pingdotgg#19432)

Co-authored-by: puccez <emanuele.puccetti@icloud.com>
Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com>
Co-authored-by: luke2x <97411838+luke2x@users.noreply.github.com>
…keep their own history (pingdotgg#19425)

Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com>
…e history (pingdotgg#19423)

Co-authored-by: Eldar Politkin <32969822+EldarPolitkin@users.noreply.github.com>
Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com>
…gdotgg#19418)

Co-authored-by: Tanner Sharon <tannermsharon@gmail.com>
Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com>
sync: upstream and mobile background connection retention
feat(server): optionally retry Codex capacity errors with backoff
Drop the upstream PostHog project key and default T3CODE_TELEMETRY_ENABLED to false, so this fork sends no product analytics unless both the flag and a user-supplied T3CODE_POSTHOG_KEY are set.

(cherry picked from commit aa21ba0)
desktop-v0.0.63 shipped from an unmerged upstream rebase, and the next
nightly built main without it. Every Mac went back about 660 upstream
commits: the older build could not read migrations 59-62 or the
granular auth scopes, so stored sessions and bearer tokens got 401.

t3-alpha-build now refuses a commit that is not on origin/main or does
not contain the latest desktop-v* tag.
desktop-v0.0.63 shipped from sync/upstream-rebase-20261014 while main
stayed on the older base. This keeps the rebase's tree and records main
as merged. #47 and the mobile copy fix are already in the rebase, #48 is
cherry-picked, and #46 (settle_after_run) is dropped: upstream's settle
on the calling thread now defers until the turn ends.
Main's October 8 sync merge resolved two fixes into the native
background-connection modules that the October 14 rebase never carried:
retention starts when the setting loads after the app backgrounds, and a
delayed Android service start only gets the remaining window. Ported
from 94c2c6e with its Robolectric test.
The build guard keeps releases on main, but an old signed zip, an
explicit lower version, or a rollback after a failed build migrated could
still put a build on a Mac that cannot read its database.

t3-alpha-build records the build's last migration id in the app and
requires an explicit version to be newer than the latest tag.
t3-alpha-install refuses a build behind the database's migrations, and
skips the rollback when the failed build already migrated.
@github-actions github-actions Bot added vouch:trusted PR author is trusted by repo permissions or the VOUCHED list. size:XXL labels Oct 16, 2026
@r4iju
r4iju merged commit bbc6c1e into main Oct 16, 2026
7 of 22 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

size:XXL vouch:trusted PR author is trusted by repo permissions or the VOUCHED list.

Projects

None yet

Development

Successfully merging this pull request may close these issues.