🐛 Swallow telemetry error and only log in warn and debug mode (#2858)

* catch nodegraph errors

* use loglevel config for telemetry

* Use getByNameAndVersion instead of getByName

* remove any usage of nodeTypes.getByName method

* deprecate getByName method
This commit is contained in:
Ahsan Virani
2022-02-24 17:15:30 +01:00
committed by GitHub
parent 2b9f3aab1b
commit 8fc1095d1e
8 changed files with 58 additions and 74 deletions

View File

@@ -24,7 +24,6 @@ import {
IRunExecutionData,
IWorfklowIssues,
IWorkflowDataProxyAdditionalKeys,
TelemetryHelpers,
Workflow,
NodeHelpers,
} from 'n8n-workflow';
@@ -224,17 +223,6 @@ export const workflowHelpers = mixins(
// Does not get used in Workflow so no need to return it
return [];
},
getByName: (nodeType: string): INodeType | INodeVersionedType | undefined => {
const nodeTypeDescription = this.$store.getters.nodeType(nodeType) as INodeTypeDescription | null;
if (nodeTypeDescription === null) {
return undefined;
}
return {
description: nodeTypeDescription,
};
},
getByNameAndVersion: (nodeType: string, version?: number): INodeType | undefined => {
const nodeTypeDescription = this.$store.getters.nodeType(nodeType, version) as INodeTypeDescription | null;