Open dancespiele opened 1 week ago
The same issue with the version 20.0.1
This is a work around which shouldn't be the final solution (nx developers should fix the executor @nx/js:node
in order to run run-many without hang
).
As I mentioned single runs works and @nx/js:node
has the option waitUntilTargets
which accept an array, there you need to add all the tasks that will execute in parallel for example:
{
"name": "app",
"$schema": "../node_modules/nx/schemas/project-schema.json",
"sourceRoot": "app/src",
"projectType": "application",
"implicitDependencies": ["!config", "!helpers", "!entities"],
"tags": [],
"targets": {
"serve": {
"executor": "@nx/js:node",
"defaultConfiguration": "development",
"dependsOn": ["build"],
"options": {
"buildTarget": "app:build",
"runBuildTargetDependencies": false,
"args": ["server"],
"waitUntilTarget": ["app:subscribe"]
},
"configurations": {
"development": {
"buildTarget": "app:build:development"
},
"production": {
"buildTarget": "app:build:production"
}
}
},
"subscribe": {
"executor": "@nx/js:node",
"defaultConfiguration": "development",
"dependsOn": ["build"],
"options": {
"buildTarget": "app:build",
"runBuildTargetDependencies": false,
"inspect": true,
"args": ["subscribe"]
},
"configurations": {
"development": {
"buildTarget": "app:build:development"
},
"production": {
"buildTarget": "app:build:production"
}
}
}
}
}
Current Behavior
I have a mono repo using nx with the plugin @nx/nest and my project have this configuration:
run-many
only works withserve
, withsubscribe
or if I rename serve it hangs but everything works with the standard commandnx run
Expected Behavior
run many
should work not only with task calledserve
GitHub Repo
minimal bug reproduction
Steps to Reproduce
nx g @nx/nest:app app
serve
toserver
or create a new task in project.json of the installed appnx run-many -t server subscribe -p app
Nx Report
Failure Logs
No response
Package Manager Version
No response
Operating System
Additional Information
No response