From 31600d374cd55cecea8c9ab26d4d467205e41d4c Mon Sep 17 00:00:00 2001 From: ilai Date: Tue, 24 Oct 2023 14:55:10 +0300 Subject: [PATCH] [cli] Bug fix - don't send the entire data in every batch Totally stpupid bug due to wrong conflict resolving... --- src/resin_cli/cli.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/resin_cli/cli.py b/src/resin_cli/cli.py index 5a8b208b..01f75599 100644 --- a/src/resin_cli/cli.py +++ b/src/resin_cli/cli.py @@ -239,7 +239,7 @@ def upsert(index_name: str, data_path: str, batch_size: int, allow_failures: boo for i in range(0, len(data), batch_size): batch = data[i:i + batch_size] try: - kb.upsert(data) + kb.upsert(batch) except Exception as e: if allow_failures and len(failed_docs) < len(data) // 10: failed_docs.extend([_.id for _ in batch])