Comparing version 0.63.0 to 0.64.0
@@ -72,3 +72,4 @@ "use strict"; | ||
.catch(async (error) => { | ||
if (error.statusCode === 401) { | ||
const statusCodeReturned = (oAuth2Options === null || oAuth2Options === void 0 ? void 0 : oAuth2Options.tokenExpiredStatusCode) === undefined ? 401 : oAuth2Options === null || oAuth2Options === void 0 ? void 0 : oAuth2Options.tokenExpiredStatusCode; | ||
if (error.statusCode === statusCodeReturned) { | ||
const tokenRefreshOptions = {}; | ||
@@ -75,0 +76,0 @@ if (oAuth2Options === null || oAuth2Options === void 0 ? void 0 : oAuth2Options.includeCredentialsOnRefreshOnBody) { |
@@ -11,2 +11,3 @@ import * as PCancelable from 'p-cancelable'; | ||
executeHook(hookName: string, parameters: any[]): Promise<void>; | ||
incomingConnectionIsEmpty(runData: IRunData, inputConnections: IConnection[], runIndex: number): boolean; | ||
addNodeToBeExecuted(workflow: Workflow, connectionData: IConnection, outputIndex: number, parentNodeName: string, nodeSuccessData: INodeExecutionData[][], runIndex: number): void; | ||
@@ -13,0 +14,0 @@ processRunExecutionData(workflow: Workflow): PCancelable<IRun>; |
@@ -6,2 +6,3 @@ "use strict"; | ||
const _1 = require("./"); | ||
const lodash_1 = require("lodash"); | ||
class WorkflowExecute { | ||
@@ -143,2 +144,11 @@ constructor(additionalData, mode, runExecutionData) { | ||
} | ||
incomingConnectionIsEmpty(runData, inputConnections, runIndex) { | ||
for (const inputConnection of inputConnections) { | ||
const nodeIncomingData = lodash_1.get(runData, `[${inputConnection.node}][${runIndex}].data.main[${inputConnection.index}]`); | ||
if (nodeIncomingData !== undefined && nodeIncomingData.length !== 0) { | ||
return false; | ||
} | ||
} | ||
return true; | ||
} | ||
addNodeToBeExecuted(workflow, connectionData, outputIndex, parentNodeName, nodeSuccessData, runIndex) { | ||
@@ -206,3 +216,5 @@ let stillDataMissing = false; | ||
if (inputData.node !== parentNodeName && checkOutputNodes.includes(inputData.node)) { | ||
continue; | ||
if (!this.incomingConnectionIsEmpty(this.runExecutionData.resultData.runData, workflow.connectionsByDestinationNode[inputData.node].main[0], runIndex)) { | ||
continue; | ||
} | ||
} | ||
@@ -236,3 +248,12 @@ if (executionStackNodes.includes(inputData.node)) { | ||
} | ||
let addEmptyItem = false; | ||
if (workflow.connectionsByDestinationNode[nodeToAdd] === undefined) { | ||
addEmptyItem = true; | ||
} | ||
else { | ||
if (this.incomingConnectionIsEmpty(this.runExecutionData.resultData.runData, workflow.connectionsByDestinationNode[nodeToAdd].main[0], runIndex)) { | ||
addEmptyItem = true; | ||
} | ||
} | ||
if (addEmptyItem === true) { | ||
this.runExecutionData.executionData.nodeExecutionStack.push({ | ||
@@ -239,0 +260,0 @@ node: workflow.getNode(nodeToAdd), |
@@ -952,2 +952,166 @@ "use strict"; | ||
}, | ||
{ | ||
description: 'should use empty data if input of sibling does not receive any data from parent', | ||
input: { | ||
workflowData: { | ||
"nodes": [ | ||
{ | ||
"parameters": {}, | ||
"name": "Start", | ||
"type": "n8n-nodes-base.start", | ||
"typeVersion": 1, | ||
"position": [ | ||
250, | ||
300, | ||
], | ||
}, | ||
{ | ||
"parameters": { | ||
"conditions": { | ||
"number": [ | ||
{ | ||
"value1": "={{$json[\"value1\"]}}", | ||
"operation": "equal", | ||
"value2": 1, | ||
}, | ||
], | ||
}, | ||
}, | ||
"name": "IF", | ||
"type": "n8n-nodes-base.if", | ||
"typeVersion": 1, | ||
"position": [ | ||
650, | ||
300, | ||
], | ||
}, | ||
{ | ||
"parameters": { | ||
"values": { | ||
"string": [], | ||
"number": [ | ||
{ | ||
"name": "value2", | ||
"value": 2, | ||
}, | ||
], | ||
}, | ||
"options": {}, | ||
}, | ||
"name": "Set2", | ||
"type": "n8n-nodes-base.set", | ||
"typeVersion": 1, | ||
"position": [ | ||
850, | ||
450, | ||
], | ||
}, | ||
{ | ||
"parameters": { | ||
"values": { | ||
"number": [ | ||
{ | ||
"name": "value1", | ||
"value": 1, | ||
}, | ||
], | ||
}, | ||
"options": {}, | ||
}, | ||
"name": "Set1", | ||
"type": "n8n-nodes-base.set", | ||
"typeVersion": 1, | ||
"position": [ | ||
450, | ||
300, | ||
], | ||
}, | ||
{ | ||
"parameters": {}, | ||
"name": "Merge", | ||
"type": "n8n-nodes-base.merge", | ||
"typeVersion": 1, | ||
"position": [ | ||
1050, | ||
300, | ||
], | ||
}, | ||
], | ||
"connections": { | ||
"Start": { | ||
"main": [ | ||
[ | ||
{ | ||
"node": "Set1", | ||
"type": "main", | ||
"index": 0, | ||
}, | ||
], | ||
], | ||
}, | ||
"IF": { | ||
"main": [ | ||
[ | ||
{ | ||
"node": "Merge", | ||
"type": "main", | ||
"index": 0, | ||
}, | ||
], | ||
[ | ||
{ | ||
"node": "Set2", | ||
"type": "main", | ||
"index": 0, | ||
}, | ||
], | ||
], | ||
}, | ||
"Set2": { | ||
"main": [ | ||
[ | ||
{ | ||
"node": "Merge", | ||
"type": "main", | ||
"index": 1, | ||
}, | ||
], | ||
], | ||
}, | ||
"Set1": { | ||
"main": [ | ||
[ | ||
{ | ||
"node": "IF", | ||
"type": "main", | ||
"index": 0, | ||
}, | ||
], | ||
], | ||
}, | ||
}, | ||
}, | ||
}, | ||
output: { | ||
nodeExecutionOrder: [ | ||
'Start', | ||
'Set1', | ||
'IF', | ||
'Set2', | ||
'Merge', | ||
], | ||
nodeData: { | ||
Merge: [ | ||
[ | ||
{ | ||
value1: 1, | ||
}, | ||
{ | ||
value2: 2, | ||
}, | ||
], | ||
], | ||
}, | ||
}, | ||
}, | ||
]; | ||
@@ -954,0 +1118,0 @@ const executionMode = 'manual'; |
{ | ||
"name": "n8n-core", | ||
"version": "0.63.0", | ||
"version": "0.64.0", | ||
"description": "Core functionality of n8n", | ||
@@ -50,3 +50,3 @@ "license": "SEE LICENSE IN LICENSE.md", | ||
"mime-types": "^2.1.27", | ||
"n8n-workflow": "~0.52.0", | ||
"n8n-workflow": "~0.53.0", | ||
"oauth-1.0a": "^2.2.6", | ||
@@ -53,0 +53,0 @@ "p-cancelable": "^2.0.0", |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
292898
3905
+ Addedn8n-workflow@0.53.0(transitive)
- Removedn8n-workflow@0.52.0(transitive)
Updatedn8n-workflow@~0.53.0