diff --git a/core/cat/rabbit_hole.py b/core/cat/rabbit_hole.py index e9e24532..9a824e3a 100644 --- a/core/cat/rabbit_hole.py +++ b/core/cat/rabbit_hole.py @@ -300,7 +300,7 @@ def store_documents(self, docs: List[Document], source: str) -> None: # every percStep send a notification in order to monito the progress # N.B. file with a len < resolution does not show any percentage # the storing should be immediate, and it's correct show only the final msg - if ((d+1) % percStep) == 0: + if ((percStep > 0) and ((d+1) % percStep) == 0): readPercentage += percResolution self.send_rabbit_thought(f"Read {readPercentage}% of {source}")