Commit graph

1 commit

Author SHA1 Message Date
Alex Garcia
8b81f40d1e Rename all IVF shadow tables in vec0Rename
vec0Rename only emitted ALTER TABLE on `<name>_ivf_cells%02d`, so renaming
an IVF-indexed vec0 table left `_ivf_centroids`, `_ivf_rowid_map`, and
`_ivf_vectors` (when quantizer != none) with the old prefix. Subsequent
queries against the renamed table broke, and DROP TABLE left those three
shadows orphaned in the schema. Same shape as the DiskANN/rescore bug fixed
in #294, just for the IVF branch.

Mirror ivf_create_shadow_tables: emit ALTER for all four IVF shadows,
gating `_ivf_vectors` on quantizer != VEC0_IVF_QUANTIZER_NONE.

Adds test-ivf-rename.py (auto-skipped on default builds via conftest's
test-ivf prefix rule) covering quantizer=none, quantizer=binary, and
DROP-after-rename. Also adds a rescore rename regression test to
test-rename.py to lock down the (already-correct) rescore path.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
2026-05-17 23:09:27 -07:00