mrmrs-15c4c5
mrmrs-15c4c5Closedinto main
3 commits · 20 files · +19 added · ~1 modified
Description
P3 merge correctness & quality suite (suites/merge): differential git merge-ort vs Oak merge engine
What
- New self-contained suite under suites/merge/ (stdlib Python, ADR-0001). No changes to core harness (lane P1 files untouched).
- Oak path exercised (phase 1):
oak pullparent-sync = Oak client merge engine, driven end-to-end viaoak clone <git>import,oak pushto a localoak serve,oak commit,oak fetch,oak merge --dry-run --json(prediction),oak pull --json; conflicts measured as the committed result after a sentinel--continue. A small RawShim supplies the/rawroute oak serve 0.105 lacks (bytes viaoak file inspect) and can stage main's head for multi-step scenarios. HostedMergeAdapter = phase-2 plug point for oakspace server merge (not built). - Oracle: real git (xcrun shim resolved via oakbench.subjects)
merge-tree --write-tree -z --messages: tree + conflict paths/types. - Classes per directional case: equal-to-git / differs-but-valid / oak-wrong / oak-unsupported / harness-error. Laws: no-lost-change, symmetry, idempotence, false/missed conflict rate, prediction agreement. JSONL rows (merge_suite_schema_version 1, evidence_class diagnostic_merge_correctness).
- Sources: gitoxide gix-merge tree/cartesian/text baselines vendored VERBATIM (MIT OR Apache-2.0, upstream acf906f8, LICENSE-MIT/APACHE + NOTICE + sha256-pinned UPSTREAM.json); git t6423 (17 cases) / t6422 (4) re-implemented from comment prose, IDs cited, no GPL text; native incident shapes (stale base C vs X with partial graph, merge base via merge parent, revert after CLI sync, lineage-less sync, criss-cross tie-break x2, clock-skew + control, t6416 criss-cross modify/delete); 40 seeded generated histories. Phase-2 hosted specs (M0a, M0b, server /sync, client-vs-server tie-break, server skew, fb-530) listed, not executed.
- tests/test_merge_suite.py: 39 hermetic instrument tests (classifier negative controls, law checks, oracle parsing, builder, vendoring byte-identity, no-GPL-text guard).
First run vs oak 0.105.0, final after QA rounds 1+2 (suites/merge/RESULTS-2026-09-28.md; worker runs/full4.jsonl): 762 cases / 387 scenarios: 328 equal-to-git, 134 differs-but-valid, 70 oak-wrong, 230 oak-unsupported (210 = gitlink matrix), 0 harness-error. Laws: idempotent 337/337, no-lost-change 460/491, symmetric 428/468, prediction agrees 494/532 (all 38 misses are failed pulls; 19 predicted clean), false-conflict 42/494 (8.5%), missed-conflict 136/494 (27.5%; 104 rename/dir-rename). Oak-wrong rows all map to filed bugs (fb-537..541, filed by o-4d 2026-09-28 from QA standalone repros) with strict rules (every reason on a row must match the same bug; exact error signatures; pinned expected_rows with new/vanished reporting): fb-540 F5 file<->dir pull fails (38; 24 violate "failed sync => worktree matches HEAD": 11 moved HEAD over a pre-merge worktree, 13 left a half-merged worktree with HEAD unchanged); fb-537 markers committed clean when an input lacks a final newline, incl. the binary case (13); fb-538 symlink targets text-merged with glued markers (8); fb-539 mode change silently lost (10); fb-541 criss-cross divergent resolutions (1). All 5 reproduce exactly as pinned; 0 unmapped.
QA round 1 (12 findings) and round 2 (R2-1 strict known-bug mapping + setup failures as harness-error + escape-route tests; R2-2 failed_pull_left_worktree_dirty invariant; R2-3 attribution wording) resolved. --resummarize RUN.jsonl re-evaluates bug mapping without running Oak.
Run: python3 suites/merge/run_merge_suite.py --workdir runs/merge --summary runs/merge-summary.json > runs/merge.jsonl
Tests: python3 -m unittest discover -s tests
Commits3
- e70815b9044a mrmrs 1 month ago
- 2f5107c20e85 mrmrs 1 month ago
- 46ad54da0178 mrmrs 1 month ago
docs/prior-art.mdmodifiedView file
This page records prior-art influence without importing another project'sbenchmark implementation. The suite may learn from behavior categories,reporting vocabulary, and measurement controls, but it must not vendor externalbenchmark code or translate external shell scripts into local Python.benchmark code or translate external shell scripts into local Python, exceptfor the recorded exception below.## Recorded Exception: gitoxide merge baselines (2026-09-28)`suites/merge/vendor/gitoxide/` vendors three gix-merge fixture scripts(`tree-baseline.sh`, `tree-cartesian-baseline.sh`, `text-baseline.sh`)verbatim from gitoxide commit `acf906f8fcdb8e8d143570737786543dc5a204a0`.- License: MIT OR Apache-2.0 (permissive). Both license texts and a `NOTICE` are carried next to the scripts. The SHA-256 of each script is pinned in `UPSTREAM.json` and checked by `tests/test_merge_suite.py`.- Rationale: the scripts are a curated, upstream-maintained catalogue of merge-ort edge cases, including an exhaustive 14x14 operation product. Re-deriving them would lose that coverage and add transcription risk. They are only executed with real Git to build fixture repositories. Git's own merge-ort computes the reference result, and no gitoxide code runs in the measured path.- Scope: this exception covers only these files. GPL sources, including Git's t64xx merge tests, stay clean-room: shapes are re-expressed from testcase prose and cited by ID, and no text is copied.## Clean-Room Rulesuites/merge/README.mdaddedView file
Loading diff…
suites/merge/RESULTS-2026-09-28.mdaddedView file
Loading diff…
suites/merge/known_bugs.jsonaddedView file
Loading diff…
suites/merge/mergesuite/__init__.pyaddedView file
Loading diff…
suites/merge/mergesuite/builder.pyaddedView file
Loading diff…
suites/merge/mergesuite/classify.pyaddedView file
Loading diff…
suites/merge/mergesuite/gitops.pyaddedView file
Loading diff…
suites/merge/mergesuite/oak_adapter.pyaddedView file
Loading diff…
suites/merge/mergesuite/runner.pyaddedView file
Loading diff…
suites/merge/mergesuite/sources.pyaddedView file
Loading diff…
suites/merge/run_merge_suite.pyaddedView file
Loading diff…
suites/merge/vendor/gitoxide/LICENSE-APACHEaddedView file
Loading diff…
suites/merge/vendor/gitoxide/LICENSE-MITaddedView file
Loading diff…
suites/merge/vendor/gitoxide/NOTICEaddedView file
Loading diff…
suites/merge/vendor/gitoxide/UPSTREAM.jsonaddedView file
Loading diff…
suites/merge/vendor/gitoxide/text-baseline.shaddedView file
Loading diff…
suites/merge/vendor/gitoxide/tree-baseline.shaddedView file
Loading diff…
suites/merge/vendor/gitoxide/tree-cartesian-baseline.shaddedView file
Loading diff…
tests/test_merge_suite.pyaddedView file
Loading diff…