Skip to content

Commit

Permalink
fix(core): reset nx daemon after command finishes (#3726)
Browse files Browse the repository at this point in the history
  • Loading branch information
fahslaj committed Jun 13, 2023
1 parent 3d62884 commit c0de66a
Showing 1 changed file with 6 additions and 3 deletions.
9 changes: 6 additions & 3 deletions libs/core/src/lib/command/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -118,6 +118,9 @@ export class Command<T extends CommandConfigOptions = CommandConfigOptions> {
(result) => {
warnIfHanging();

// Now that we have made our calls to the daemon, we need it to exit so that the overall process can too
daemonClient.reset();

resolve(result);
},
(err) => {
Expand All @@ -137,6 +140,9 @@ export class Command<T extends CommandConfigOptions = CommandConfigOptions> {

warnIfHanging();

// Now that we have made our calls to the daemon, we need it to exit so that the overall process can too
daemonClient.reset();

// error code is handled by cli.fail()
reject(err);
}
Expand Down Expand Up @@ -213,9 +219,6 @@ export class Command<T extends CommandConfigOptions = CommandConfigOptions> {
this.projectFileMap,
this.project.packageConfigs
);

// Now that we have made our two calls to the daemon, we need it to exit so that the overall process can too
daemonClient.reset();
}

configureEnvironment() {
Expand Down

0 comments on commit c0de66a

Please sign in to comment.