From d3b78e291ece5355b0829c935a3142b6078287c9 Mon Sep 17 00:00:00 2001 From: Michael Auerswald Date: Thu, 15 Jun 2023 11:52:21 +0200 Subject: [PATCH] fix(editor): Show execution error as message (#6431) show execution error as message --- packages/editor-ui/src/plugins/i18n/locales/en.json | 1 + packages/editor-ui/src/views/NodeView.vue | 7 ++++++- 2 files changed, 7 insertions(+), 1 deletion(-) diff --git a/packages/editor-ui/src/plugins/i18n/locales/en.json b/packages/editor-ui/src/plugins/i18n/locales/en.json index 808314759b..6b6a41a322 100644 --- a/packages/editor-ui/src/plugins/i18n/locales/en.json +++ b/packages/editor-ui/src/plugins/i18n/locales/en.json @@ -864,6 +864,7 @@ "nodeView.runButtonText.executeWorkflow": "Execute Workflow", "nodeView.runButtonText.executingWorkflow": "Executing Workflow", "nodeView.runButtonText.waitingForTriggerEvent": "Waiting for Trigger Event", + "nodeView.showError.workflowError": "Workflow execution finished with an error", "nodeView.showError.getWorkflowDataFromUrl.title": "Problem loading workflow", "nodeView.showError.importWorkflowData.title": "Problem importing workflow", "nodeView.showError.mounted1.message": "There was a problem loading init data", diff --git a/packages/editor-ui/src/views/NodeView.vue b/packages/editor-ui/src/views/NodeView.vue index c0df57b71f..bbc304e03a 100644 --- a/packages/editor-ui/src/views/NodeView.vue +++ b/packages/editor-ui/src/views/NodeView.vue @@ -776,9 +776,14 @@ export default defineComponent({ if (!nodeErrorFound && data.data.resultData.error.stack) { // Display some more information for now in console to make debugging easier - // TODO: Improve this in the future by displaying in UI console.error(`Execution ${executionId} error:`); // eslint-disable-line no-console console.error(data.data.resultData.error.stack); // eslint-disable-line no-console + this.showMessage({ + title: this.$locale.baseText('nodeView.showError.workflowError'), + message: data.data.resultData.error.message, + type: 'error', + duration: 0, + }); } } if ((data as IExecutionsSummary).waitTill) {