From f415f22ccb1c83e819ddfbb77144192113fcedbc Mon Sep 17 00:00:00 2001 From: Kelly McDonald Date: Mon, 20 Jul 2020 10:12:15 -0400 Subject: [PATCH] Add warning message when we fail due to syntax error and then we try to look up the class as a backup --- crc/services/workflow_processor.py | 3 +++ 1 file changed, 3 insertions(+) diff --git a/crc/services/workflow_processor.py b/crc/services/workflow_processor.py index 4ca3f20a..e02957d9 100644 --- a/crc/services/workflow_processor.py +++ b/crc/services/workflow_processor.py @@ -23,6 +23,7 @@ from crc.models.file import FileDataModel, FileModel, FileType from crc.models.workflow import WorkflowStatus, WorkflowModel, WorkflowSpecDependencyFile from crc.scripts.script import Script from crc.services.file_service import FileService +from crc import app class CustomBpmnScriptEngine(BpmnScriptEngine): @@ -49,6 +50,8 @@ class CustomBpmnScriptEngine(BpmnScriptEngine): except SyntaxError as e: failedOnce = True prevError = script + app.logger.warning('We experienced a syntax error, but we are going to try the old method on ' + '"%s"'%script) else: commands = commands[1:]