Another process, with id #######, is currently running ngcc

Angular

Angular Problem Overview


I'm trying to build and serve my project. It was working properly, I updated it from git and then suddenly when I serve it, there is an Error saying "Another process, with id 29800, is currently running ngcc." I retried "npm i", also restarted the IDE and even pc, but it still says the same.

Angular Solutions


Solution 1 - Angular

This happens when ngcc (Angular compatibility compiler) is not finished doing what it does, you must have enabled ivy in your Angular project. read here for more info about ivy.

  1. First try to run npm install again, to see if it fixes your problem.
  2. Try to run ngcc manually.
  3. remove this file node_modules/@angular/compiler-cli/ngcc/__ngcc_lock_file__
  4. If none of the above worked, then remove node_modules directory and try npm i again.

Solution 2 - Angular

The Laptop Crashed and I got this problem after restart. Removing the below file from ionic project solved the problem.

node_modules/@angular/compiler-cli/ngcc/ngcc_lock_file

Solution 3 - Angular

Try deleting your ngcc_lock_file in the path:

node_modules/@angular/compiler-cli/ngcc/ngcc_lock_file

It's work for me.

Solution 4 - Angular

Fix this all in one easy command:

run npm ci

this will delete node_modules and npm install

Solution 5 - Angular

just remove the node_modulesthen run npm i

Solution 6 - Angular

I deleted the file node_modules/@angular/compiler-cli/ngcc/ngcc_lock_file_ from the node_modules folder and its working fine.

Solution 7 - Angular

I deleted the file node_modules/@angular/compiler-cli/ngcc/ngcc_lock_file_ from the node_modules folder and its working fine. angular v10

Solution 8 - Angular

Just run

ionic repair

And select Yes

Solution 9 - Angular

deleting lock file in nodes module at the following location will fix this errors

*C:\Users\OneDrive\Desktop\app\node_modules\@angular\compiler-cli\ngcc\src\locking*

delete the lock-file javascript file over there.

if it still shows the same error then delete the entire lock-files folder ,restart command prompt and then it will run

Solution 10 - Angular

Also if above solutions, dosen´t work it could be that the pipeline has too little space to work with side processes. What you could do is go to angular.json and search for this object:

"budgets": [{"type": "initial","maximumWarning": "4mb","maximumError": "5mb"}]

and raise the limits on maximumError for example.

More about budgets here: angular.io/guide

Solution 11 - Angular

Had the same issue running angular with a docker file, and like suggested here I deleted ngcc_lock_file BEFORE running npm install

enter image description here

Solution 12 - Angular

simply run rm -rf node_modules && npm install

Attributions

All content for this solution is sourced from the original question on Stackoverflow.

The content on this page is licensed under the Attribution-ShareAlike 4.0 International (CC BY-SA 4.0) license.

Content TypeOriginal AuthorOriginal Content on Stackoverflow
QuestionhadimbjView Question on Stackoverflow
Solution 1 - AngularazerafatiView Answer on Stackoverflow
Solution 2 - AngularLalit RaneView Answer on Stackoverflow
Solution 3 - Angularsantosh ghimireView Answer on Stackoverflow
Solution 4 - AngularBen YeeView Answer on Stackoverflow
Solution 5 - AngularAbdallh AbukhaderView Answer on Stackoverflow
Solution 6 - AngularManoj TyagiView Answer on Stackoverflow
Solution 7 - AngularMilad JafariView Answer on Stackoverflow
Solution 8 - AngularRafael FrancoView Answer on Stackoverflow
Solution 9 - Angularvikashjha.tpView Answer on Stackoverflow
Solution 10 - AngularMichael RView Answer on Stackoverflow
Solution 11 - AngularAshesAndDustView Answer on Stackoverflow
Solution 12 - AngularVinicius CardosoView Answer on Stackoverflow