fix(core): Fix disabled parent output in partial execution (#3946)

🐛 Skip disabled parent in partial execution
This commit is contained in:
Iván Ovejero
2022-09-01 15:43:48 +02:00
committed by GitHub
parent 936cb11789
commit c8743ff6ca
2 changed files with 10 additions and 2 deletions

View File

@@ -192,6 +192,9 @@ export class WorkflowExecute {
for (const connections of incomingNodeConnections.main) {
for (let inputIndex = 0; inputIndex < connections.length; inputIndex++) {
connection = connections[inputIndex];
if (workflow.getNode(connection.node)?.disabled) continue;
incomingData.push(
// eslint-disable-next-line @typescript-eslint/no-non-null-assertion
runData[connection.node][runIndex].data![connection.type][connection.index]!,
@@ -257,7 +260,10 @@ export class WorkflowExecute {
// Only run the parent nodes and no others
let runNodeFilter: string[] | undefined;
// eslint-disable-next-line prefer-const
runNodeFilter = workflow.getParentNodes(destinationNode);
runNodeFilter = workflow
.getParentNodes(destinationNode)
.filter((parentNodeName) => !workflow.getNode(parentNodeName)?.disabled);
runNodeFilter.push(destinationNode);
this.runExecutionData = {