Closed wizardnet972 closed 2 years ago
maybe wherever you create a folder in dist
, check before if they exist?
Could you please provide a repo we can pull down to reproduce the issue?
This issue has been automatically marked as stale because it hasn't had any recent activity. It will be closed in 14 days if no further activity occurs. If we missed this issue please reply to keep it active. Thanks for being a part of the Nx community! 🙏
@FrozenPandaz Hey :) I'm still trying to reproduce this issue. I think it's happened because of resource collision.
I debug the nx code though run-many.js
and I found out that something is failed in finally
section:
https://github.com/nrwl/nx/blob/4b21ab9502f8fcc4c20db3478adcb7aa5f7a934a/packages/workspace/src/tasks-runner/default-tasks-runner.ts#L60
so the error caught in the catch
section:
https://github.com/nrwl/nx/blob/4b21ab9502f8fcc4c20db3478adcb7aa5f7a934a/packages/workspace/src/tasks-runner/default-tasks-runner.ts#L56
Not yet sure why.
But as far I can see I add project.json
to the root project and add the entry in workspace.json
.
When I run yarn nx run-many --target build --all
, nx detect also "workspace" project. which triggers to build of the default project.
So I think because nx run the commands in parallel the resources of the cache/directory is occupied (in use/exist).
Think about this, I build every project including the default project. also nx build the workspace project which is the default project in parallel. same cache same files and directory.
Maybe the affected and the graph workspace should not build the default project. also what if I don't have a default project?
I had this problem for months. I will appreciate your help in this matter :)
I have the same issue any updates please ?
This issue has been closed for more than 30 days. If this issue is still occuring, please open a new issue with more recent context.
Current Behavior
Nx runs unnecessary build to defaultProject (nx.json) when affected:libs returns "workspace". If I have defaultProject I got an error:
I run
build
onapp-a
andapp-b
(run-many) but the default isapp-c
.Expected Behavior
if I don't have
defaultProject
then no build should run.Steps to Reproduce
This issue may not be prioritized if details are not provided to help us reproduce the issue.
Failure Logs
Environment