From 7dedb99daed97632de0bebb7fc0f6aa65dd6a9dc Mon Sep 17 00:00:00 2001 From: jonaswinkler Date: Tue, 26 Jan 2021 01:15:27 +0100 Subject: [PATCH] fix status reports for consumption directory status messages --- src/documents/consumer.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/documents/consumer.py b/src/documents/consumer.py index f4a40cbb9..aef8c6345 100755 --- a/src/documents/consumer.py +++ b/src/documents/consumer.py @@ -1,6 +1,7 @@ import datetime import hashlib import os +import uuid from subprocess import Popen import magic @@ -150,7 +151,7 @@ class Consumer(LoggingMixin): self.override_correspondent_id = override_correspondent_id self.override_document_type_id = override_document_type_id self.override_tag_ids = override_tag_ids - self.task_id = task_id + self.task_id = task_id or str(uuid.uuid4()) self._send_progress(self.filename, 0, 100, 'WORKING', 'Received new file.')