perf: load authenticated status before the full mail cache [skip release]#108

merged5
perf/emc2-storage-startup
perf/emc2-web-startup-compaction
opened5d agobyPPB
View on GitHubTwo-way sync enabledPR last imported 3d ago

What this changes

Load authenticated account status before the full mail cache. Keep counts pending, offer retry, and delay automatic browser sync until a complete snapshot has loaded. Isolate the browser-session regression listener from host services.

Related: #106, #107.

This is one layer of the ordered stack #107, #108, #104, #112, #84. [skip release] suppresses automatic publication from the squash commit.

Ownership and scope

  • Task owner: pekth.
  • Delivery owner (one writer): Codex acting for pekth.
  • Owned paths: bootstrap API and renderer readiness, focused tests, docs.
  • Base branch and feature branch: main and perf/emc2-web-startup-compaction.
  • Related issue or pull request: listed above.
  • Coordination search completed; existing PRs reused and original commits preserved with fast-forward branch updates.

How it was verified

  • Final head: 0c4c57397b52260d764d5c84e5bd957d578c847e; merge base: 038ff3b044431196cf05f6240b4f9bd52a417f29.

  • Broad bounded baseline: 1,343 tests passed; one fixed-port browser-session test failed. Its diagnosed ephemeral-listener repair subsequently passed in a separate bounded run. This is complete passing test-path coverage across separate runs, not a monolithic passing run.

  • Bootstrap regression: both pending and failed full reads reproduced unwanted automatic sync before the fix; all 10 bootstrap scenarios passed after the loaded guard.

  • Combined stack strict TypeScript, renderer and desktop build passed on Node 24.22.1.

  • Combined focused integration checks: all 207 passed, zero failed or skipped, through the bounded serial runner.

  • Isolated Linux source desktop startup passed under Xvfb: renderer loaded, database opened, isolated API and background close passed; packaged false, supported linux-local key fallback. This is source startup proof only.

  • Whitespace checks, changed contributor/changelog relative links and noreply commit-metadata check passed.

  • For application changes, npm test and npm run build pass; test coverage uses the separate bounded runs described above.

  • No private mail, account data, credentials or runtime paths are included.

  • Affected documentation and changelog are updated.

Review

  • Independent reviewer: Codex gpt-6.1-sol, high effort; SHIP, source only. Existing matching source reviews reused; fixes and integration resolutions reviewed separately.
  • Reviewed combined head: a4d8b230737abd4b30ae133f33cb6386bd6c9501; tree: e820385fac0d18fd257b203f6ffc2981123c37b4. Final stack head f2521f8b3446d471a200427ebae4bcf91b97b37b has that identical tree; only commit ancestry changed to put listener isolation in the bottom layer.
  • Required checks and approvals: forge state must be read separately; skipped or absent CI is not a passing hosted run.
  • Blocking source feedback resolved. Squash queue and resolved conversations remain required.
  • Native/installed app acceptance, phone geometry and passkey prompts, platform credential persistence, real providers and release artifact acceptance remain unknown.

Model: gpt-6.1-sol. Harness: Codex in T3 Code.

Landing receipt

  • Rebased onto main 038ff3b044431196cf05f6240b4f9bd52a417f29 before merge. Final head: 0c4c57397b52260d764d5c84e5bd957d578c847e.
  • Merged through the protected squash queue as b54b3749c79a47aa9eb6c520e47a18b53db9150e.
  • Application, build, test, dependency and workflow inputs match the previously reviewed and executed candidate. Passing evidence was reused for those unchanged inputs. The rebased source equivalence and updated release documentation received an independent review; the changelog wording finding was corrected.
  • Automatic publication was suppressed for this intermediate merge.

Checks

3 skipped
All checks passed
0c4c573

Added 5 commits

  • docs: require PR closure reasons and links to fixes (#113)bab4105
  • docs: apply closure explanations to issues and PRs (#114)0ef892e
  • perf: reduce mail snapshot copying and unnecessary vacuuming [skip release] (#107)038ff3b
  • fix: wait for complete mail before automatic browser sync0c4c573
  • perf: load authenticated status before the full mail cache134d277

Closure reconciliation for https://github.com/collection-of-things/aggregate-mail/issues/106: Reduced summary copying, conditional compaction and authenticated status-first bootstrap are merged. The old pending-merge status is superseded.

The issue is being closed as completed because this fixing PR is merged. Closure reason: https://github.com/collection-of-things/aggregate-mail/issues/106#issuecomment-6461136126

Installed/browser performance and real-provider acceptance are not established by this closure.