Skip to content

Commit 5dc0264

Browse files
Fix bug for Index clear_history (#522)
We always need to have `0` as the first ingestion timestamp, even if we don't have respective write fragments in the base index arrays. If not, `updates` that are before the `first_ingestion_timestamp` will not be visible.
1 parent 58692cd commit 5dc0264

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

apis/python/src/tiledb/vector_search/index.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -638,7 +638,7 @@ def clear_history(
638638
new_partition_history = []
639639
i = 0
640640
for ingestion_timestamp in ingestion_timestamps:
641-
if ingestion_timestamp > timestamp:
641+
if ingestion_timestamp == 0 or ingestion_timestamp > timestamp:
642642
new_ingestion_timestamps.append(ingestion_timestamp)
643643
new_base_sizes.append(base_sizes[i])
644644
new_partition_history.append(partition_history[i])

0 commit comments

Comments
 (0)