0

I am not able to build angular (angular 6).This happened after I upgraded node modules. I get this error:

Failed to capture fingerprint of output files for task ':pbr-angular-common:setupAngular' property '$1' during up-to-date check.

Could not list contents of '/Users/xxx/git/xxx/angular-common/node_modules/@angular-devkit/build-angular/node_modules/.bin/node-gyp'. Couldn't follow symbolic link.

This are the things I tried:

  1. Removed folders from .bin
  2. Removed .bin folder
  3. Removed node_modules compeltely and reinstalled as mentioned in this link [How do I completely uninstall Node.js, and reinstall from beginning (Mac OS X)
  4. Removed symbolic links as mentioned in this link:
    [https://github.com/srs/gradle-node-plugin/issues/202][2]
  5. Cleared npm cache (npm clean cache)
  6. Cleared .gradle (includes gradle nodejs cache)
  7. Did gradlew clean build re deploy
  8. Did brew uninstall node, brew install node, brew unlink node && link node

Here are the nodejs and npm versions I use

npm --version
6.11.3
node --version
v12.11.1

I am working on MacOS mojave version 10.14.5. Please Please let me know how to fix this issue.

Khaled Lela
  • 5,495
  • 5
  • 39
  • 63
javagirl
  • 31
  • 5

1 Answers1

0

I got this error while building the application and "rm -rf node_modules && npm i" didn't worked for me.

this error was because of node version 12

following commands solved the issue for me

sudo npm cache clean -f
sudo npm install -g n
sudo n 10.9.0

so basically i just downgraded my node version