From fac77a2f73defc7f40566b267feaec9f03c96b35 Mon Sep 17 00:00:00 2001 From: Roberto Rosario Date: Wed, 24 Jul 2019 02:25:49 -0400 Subject: [PATCH] Workaround for the OCR task-inside-task issue Thanks to Jakob Haufe (@sur5r) for the solution. https://gitlab.com/sur5r/mayan-edms/commit/2423254aa4fd85c4420b59f846c05b1a89f5ee99 Signed-off-by: Roberto Rosario --- mayan/apps/ocr/managers.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/mayan/apps/ocr/managers.py b/mayan/apps/ocr/managers.py index f6a0b68978..7d1e912472 100644 --- a/mayan/apps/ocr/managers.py +++ b/mayan/apps/ocr/managers.py @@ -35,7 +35,7 @@ class DocumentPageOCRContentManager(models.Manager): ) ) - cache_filename = task.get(timeout=DOCUMENT_IMAGE_TASK_TIMEOUT) + cache_filename = task.get(timeout=DOCUMENT_IMAGE_TASK_TIMEOUT, disable_sync_subtasks=False) with document_page.cache_partition.get_file(filename=cache_filename).open() as file_object: document_page_content, created = DocumentPageOCRContent.objects.get_or_create(