Skip to content

Commit

Permalink
fix(core): do not duplicate output of tasks executed in batch mode (#…
Browse files Browse the repository at this point in the history
  • Loading branch information
leosvelperez authored Jul 14, 2023
1 parent 178975c commit d489de5
Showing 1 changed file with 0 additions and 21 deletions.
21 changes: 0 additions & 21 deletions packages/nx/src/tasks-runner/forked-process-task-runner.ts
Original file line number Diff line number Diff line change
Expand Up @@ -78,30 +78,9 @@ export class ForkedProcessTaskRunner {
}
});

const printedTasks = new Set<string>();
p.on('message', (message: BatchMessage) => {
switch (message.type) {
case BatchMessageType.CompleteTask: {
this.options.lifeCycle.printTaskTerminalOutput(
batchTaskGraph.tasks[message.task],
message.result.success ? 'success' : 'failure',
message.result.terminalOutput
);
printedTasks.add(message.task);

break;
}
case BatchMessageType.CompleteBatchExecution: {
Object.entries(message.results).forEach(([taskName, result]) => {
if (!printedTasks.has(taskName)) {
this.options.lifeCycle.printTaskTerminalOutput(
batchTaskGraph.tasks[taskName],
result.success ? 'success' : 'failure',
result.terminalOutput
);
}
});

res(message.results);
break;
}
Expand Down

1 comment on commit d489de5

@vercel
Copy link

@vercel vercel bot commented on d489de5 Jul 14, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Successfully deployed to the following URLs:

nx-dev – ./

nx-dev-nrwl.vercel.app
nx-five.vercel.app
nx.dev
nx-dev-git-master-nrwl.vercel.app

Please sign in to comment.