Skip to content

Commit 87b0336

Browse files
committed
Fix shallow copy issue when splitting long index records
Fixes #149
1 parent 1284cee commit 87b0336

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

gecko/index_on_algolia.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,7 @@
2626
# Split long documents into smaller parts.
2727
for record in records:
2828
if len(record['content']) > 5000:
29-
new_record = record
29+
new_record = record.copy()
3030
new_record['content'] = new_record['content'][4900:]
3131
record['content'] = record['content'][:5000]
3232
records.append(new_record)

0 commit comments

Comments
 (0)