test(index): add a fragment reuse contract harness across index types #10639
ACTION NEEDED
Lance follows the Conventional Commits specification for release automation.
The PR title and description are used as the merge commit message. Please update your PR title and description to match the specification.
For details on the error please inspect the "PR Title Check" action.
Claude Code Review
This repository is configured for manual code reviews. Comment @claude review for a one-time review, or @claude review always to subscribe this PR to a review on every future push.
<sub>Tip: disable this comment in your organization's Code Review settings.</sub>
✅ Gate recommendation: approve.
The independent oracle is a useful guard for the fragment-reuse refactor. The two ignored tagged full-text cases reproduce the existing empty-coverage failure tracked in #10623.
✅ Gate recommendation: approve.
The live-row model now checks data preservation as well as indexed query results through warm and cold handles. The two ignored tagged full-text cases continue to reproduce the pre-existing empty-coverage failure tracked in #10623.
nit: Could we assert that the expected index segment is used at checkpoints where it should still have coverage? MAYBE If FRI accidentally drops that coverage, a flat scan can return the same rows and pass the result check.
Approved these changes.
That's a good idea. I'll see if I can modify the tests to detect that.
Nice change! Merging :)
zhangyue19921010
wjones127
Summary
Adds a contract test for the fragment reuse index (FRI): whatever history it records, an indexed query must return exactly the rows a query computed from the table's current contents returns. It is the guard for the upcoming consolidation of FRI logic into one module.
The oracle scans the table and evaluates each query in Rust, never consulting an index or the history. A second short scenario follows OSS-2763 (deferred then eager compaction). Maintenance steps may refuse with
InvalidInput/NotSupported; returning wrong or missing rows fails.Evidence
v = 13returns nothing; FTS returns only the appended row).All 30 cases run in under a second.
Merge Risk
Door: two-way; tests only.
Blast Radius: none.
🤖 Generated with Claude Code