Skip to content

feat: TRAC-925 upgrade: whole-tree merge engine and index staging - #3064

Merged
chanceaclark merged 2 commits into
alphafrom
chancellorclark/ltrac-958-upgrade-whole-tree-index-staging
Jun 26, 2026
Merged

feat: TRAC-925 upgrade: whole-tree merge engine and index staging#3064
chanceaclark merged 2 commits into
alphafrom
chancellorclark/ltrac-958-upgrade-whole-tree-index-staging

Conversation

@chanceaclark

@chanceaclark chanceaclark commented Jun 25, 2026

Copy link
Copy Markdown
Contributor

Jira: TRAC-925

PR 2 of 4 for catalyst upgrade (LTRAC-956). Stacks on TRAC-924 (#3063).

What/Why?

Adds the whole-tree merge engine (git merge-tree --write-tree) and the index staging layer (applyIndexState).

The whole-tree engine is the default (used when git >= 2.38). Key design decisions:

  • Three sides (base/ours/theirs) are snapshotted as commits in a throwaway object store with separate GIT_INDEX_FILE per side — this lets all three git add -A calls run in parallel without index races, while still sharing the object store for blob dedup
  • git merge-tree -z --name-only output is NUL-delimited: <tree-oid>\0<conflicted-path>\0...\0\0<messages>. The empty field after the last conflicted path is the terminator; everything after is informational and ignored
  • checkout-index only writes, never removes — deleted paths are identified via git diff --no-renames --name-status oursTree mergedTree and removed separately
  • NULL_OID is detected via git rev-parse --show-object-format to support SHA-256 repos (OID = 64 hex vs 40). The OID regex already accepts 40–64; NULL_OID now matches

applyIndexState registers conflicted files as real unmerged index entries (stages 1/2/3) so VS Code's merge UI activates. MERGE_HEAD is intentionally absent — resolving is a normal git add + commit, not a merge commit.

Testing

pnpm test upgrade.spec

Covers: resolveStrategy, applyIndexState, mergeCore engine: tree × 7 (same contract as per-file — both must agree), mergeCoreTree rename fidelity.

Migration

No user-visible changes yet.

@vercel

vercel Bot commented Jun 25, 2026

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
catalyst Ready Ready Preview, Comment Jun 26, 2026 7:01pm

Request Review

@changeset-bot

changeset-bot Bot commented Jun 25, 2026

Copy link
Copy Markdown

⚠️ No Changeset found

Latest commit: 127c5ac

Merging this PR will not cause a version bump for any packages. If these changes should not result in a new version, you're good to go. If these changes should result in a version bump, you need to add a changeset.

This PR includes no changesets

When changesets are added to this PR, you'll see the packages that this PR includes changesets for and the associated semver types

Click here to learn what changesets are, and how to add one.

Click here if you're a maintainer who wants to add a changeset to this PR

@github-actions

github-actions Bot commented Jun 25, 2026

Copy link
Copy Markdown
Contributor

Bundle Size Report

Comparing against baseline from 81b88df (2026-06-26).

No bundle size changes detected.

@chanceaclark
chanceaclark force-pushed the chancellorclark/ltrac-957-upgrade-utilities-per-file-engine branch from 9c3e3f8 to 9ba2d0f Compare June 25, 2026 20:49
@chanceaclark
chanceaclark force-pushed the chancellorclark/ltrac-958-upgrade-whole-tree-index-staging branch from 8130e49 to 1c9aa30 Compare June 25, 2026 20:50
@chanceaclark
chanceaclark force-pushed the chancellorclark/ltrac-957-upgrade-utilities-per-file-engine branch from 9ba2d0f to f182ca3 Compare June 25, 2026 21:02
@chanceaclark
chanceaclark force-pushed the chancellorclark/ltrac-958-upgrade-whole-tree-index-staging branch from 1c9aa30 to cceeb22 Compare June 25, 2026 21:03
@chanceaclark
chanceaclark force-pushed the chancellorclark/ltrac-957-upgrade-utilities-per-file-engine branch from f182ca3 to 9e76666 Compare June 25, 2026 21:14
@chanceaclark
chanceaclark force-pushed the chancellorclark/ltrac-958-upgrade-whole-tree-index-staging branch from cceeb22 to da9ca32 Compare June 25, 2026 21:14
@chanceaclark
chanceaclark force-pushed the chancellorclark/ltrac-957-upgrade-utilities-per-file-engine branch from 9e76666 to 5048bea Compare June 25, 2026 22:10
@chanceaclark
chanceaclark force-pushed the chancellorclark/ltrac-958-upgrade-whole-tree-index-staging branch from e5aa299 to 85368ef Compare June 25, 2026 22:51
@chanceaclark
chanceaclark marked this pull request as ready for review June 25, 2026 22:53
@chanceaclark
chanceaclark requested a review from a team as a code owner June 25, 2026 22:53
@github-actions

github-actions Bot commented Jun 25, 2026

Copy link
Copy Markdown
Contributor

Unlighthouse Performance Comparison — Vercel

Comparing PR preview deployment Unlighthouse scores vs production Unlighthouse scores.

Summary Score

Aggregate score across all categories as reported by Unlighthouse.

Prod Desktop Prod Mobile Preview Desktop Preview Mobile
Score 89 93 92 95

Category Scores

Category Prod Desktop Prod Mobile Preview Desktop Preview Mobile
Performance 75 88 76 81
Accessibility 95 95 95 92
Best Practices 100 100 100 100
SEO 88 88 100 100

Core Web Vitals

Metric Prod Desktop Prod Mobile Preview Desktop Preview Mobile
LCP 3.3 s 3.8 s 3.6 s 5.1 s
CLS 0 0 0.001 0
FCP 1.4 s 1.2 s 1.2 s 1.1 s
TBT 0 ms 0 ms 0 ms 0 ms
Max Potential FID 30 ms 40 ms 40 ms 50 ms
Time to Interactive 3.3 s 3.9 s 3.6 s 5.1 s

Full Unlighthouse report →

@chanceaclark
chanceaclark force-pushed the chancellorclark/ltrac-957-upgrade-utilities-per-file-engine branch from 5048bea to da25f95 Compare June 26, 2026 16:15
@chanceaclark
chanceaclark force-pushed the chancellorclark/ltrac-958-upgrade-whole-tree-index-staging branch from 85368ef to 39f5903 Compare June 26, 2026 16:15
@chanceaclark
chanceaclark force-pushed the chancellorclark/ltrac-958-upgrade-whole-tree-index-staging branch from 39f5903 to 1ed7139 Compare June 26, 2026 18:29
Base automatically changed from chancellorclark/ltrac-957-upgrade-utilities-per-file-engine to alpha June 26, 2026 18:59
chanceaclark and others added 2 commits June 26, 2026 13:00
Co-Authored-By: Claude Sonnet 4.6 (1M context) <noreply@anthropic.com>
…ngine tests

Co-Authored-By: Claude Sonnet 4.6 (1M context) <noreply@anthropic.com>
@chanceaclark
chanceaclark force-pushed the chancellorclark/ltrac-958-upgrade-whole-tree-index-staging branch from 1ed7139 to 127c5ac Compare June 26, 2026 19:00
@chanceaclark
chanceaclark merged commit 67be8ab into alpha Jun 26, 2026
6 of 9 checks passed
@chanceaclark
chanceaclark deleted the chancellorclark/ltrac-958-upgrade-whole-tree-index-staging branch June 26, 2026 19:00
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.

3 participants