question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Cannot Install By Angular CLI

See original GitHub issue

Error occur as below, need help : C:\xampp\htdocs\ANGULAR_PROJECT\vQr>npm i @zxing/ngx-scanner@latest --save

sharp@0.19.1 install C:\xampp\htdocs\ANGULAR_PROJECT\vQr\node_modules\sharp node-gyp rebuild

C:\xampp\htdocs\ANGULAR_PROJECT\vQr\node_modules\sharp>if not defined npm_config_node_gyp (node "C:\Users\yen-yee.wong\AppData\Roaming\npm\node_modules\npm\node_modules\npm-lifecycle\node-gyp-bin\\..\..\node_modules\node-gyp\bin\node-gyp.js" rebuild )  else (node "C:\Users\yen-yee.wong\AppData\Roaming\npm\node_modules\npm\node_modules\node-gyp\bin\node-gyp.js" rebuild )
gyp ERR! configure error
gyp ERR! stack Error: Can't find Python executable "python", you can set the PYTHON env variable.
gyp ERR! stack     at PythonFinder.failNoPython (C:\Users\yen-yee.wong\AppData\Roaming\npm\node_modules\npm\node_modules\node-gyp\lib\configure.js:483:19)
gyp ERR! stack     at PythonFinder.<anonymous> (C:\Users\yen-yee.wong\AppData\Roaming\npm\node_modules\npm\node_modules\node-gyp\lib\configure.js:508:16)
gyp ERR! stack     at C:\Users\yen-yee.wong\AppData\Roaming\npm\node_modules\npm\node_modules\graceful-fs\polyfills.js:284:29
gyp ERR! stack     at FSReqWrap.oncomplete (fs.js:152:21)
gyp ERR! System Windows_NT 6.1.7601
gyp ERR! command "C:\\Program Files\\nodejs\\node.exe" "C:\\Users\\yen-yee.wong\\AppData\\Roaming\\npm\\node_modules\\npm\\node_modules\\node-gyp\\bin\\node-gyp.js" "rebuild"
gyp ERR! cwd C:\xampp\htdocs\ANGULAR_PROJECT\vQr\node_modules\sharp
gyp ERR! node -v v8.9.4
gyp ERR! node-gyp -v v3.6.2
gyp ERR! not ok
npm WARN rollback Rolling back tar@4.4.0 failed (this is probably harmless): EPERM: operation not permitted, scandir 'C:\xampp\htdocs\ANGULAR_PROJECT\vQr\node_modules\sharp\node_modules'
npm WARN rollback Rolling back node-pre-gyp@0.6.39 failed (this is probably harmless): EPERM: operation not permitted, rmdir 'C:\xampp\htdocs\ANGULAR_PROJECT\vQr\node_modules\fsevents\node_modules'
npm WARN rollback Rolling back ajv@4.11.8 failed (this is probably harmless): EPERM: operation not permitted, rmdir 'C:\xampp\htdocs\ANGULAR_PROJECT\vQr\node_modules\fsevents\node_modules'
npm WARN @angular/cdk@5.0.4 requires a peer of @angular/core@~5.1.1 but none is installed. You must install peer dependencies yourself.
npm WARN @angular/cdk@5.0.4 requires a peer of @angular/common@~5.1.1 but none is installed. You must install peer dependencies yourself.
npm WARN @angular/flex-layout@2.0.0-beta.12 requires a peer of @angular/core@~5.1.0 but none is installed. You must install peer dependencies yourself.
npm WARN @angular/flex-layout@2.0.0-beta.12 requires a peer of @angular/common@~5.1.0 but none is installed. You must install peer dependencies yourself.
npm WARN @angular/material@5.0.4 requires a peer of @angular/core@~5.1.1 but none is installed. You must install peer dependencies yourself.
npm WARN @angular/material@5.0.4 requires a peer of @angular/common@~5.1.1 but none is installed. You must install peer dependencies yourself.
npm WARN ng2-qrcode-reader@0.0.1 requires a peer of @angular/core@^4.0.0 but none is installed. You must install peer dependencies yourself.
npm WARN ngx-carousel@1.3.5 requires a peer of @angular/core@^2.4.0 || ^4.0.0 but none is installed. You must install peer dependencies yourself.
npm WARN ngx-carousel@1.3.5 requires a peer of @angular/common@^2.4.0 || ^4.0.0 but none is installed. You must install peer dependencies
yourself.
npm WARN ngx-qrcode3@0.3.0 requires a peer of @angular/core@^4.0.0 but none is installed. You must install peer dependencies yourself.
npm WARN ngx-zxing@0.3.4 requires a peer of @angular/core@^4.0.0 but none is installed. You must install peer dependencies yourself.
npm WARN optional SKIPPING OPTIONAL DEPENDENCY: fsevents@1.1.3 (node_modules\fsevents):
npm WARN notsup SKIPPING OPTIONAL DEPENDENCY: Unsupported platform for fsevents@1.1.3: wanted {"os":"darwin","arch":"any"} (current: {"os":"win32","arch":"x64"})

npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! sharp@0.19.1 install: `node-gyp rebuild`
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the sharp@0.19.1 install script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.

Issue Analytics

  • State:closed
  • Created 6 years ago
  • Comments:6 (5 by maintainers)

github_iconTop GitHub Comments

1reaction
odahcamcommented, Mar 15, 2018

Package updated and working: https://zxing-ngx-scanner.stackblitz.io/

1reaction
werthdavidcommented, Mar 15, 2018

This is probably a problem with your environment, please try to install:

npm install --global --production windows-build-tools

…and try again.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Not able to install @angular/cli using npm - Stack Overflow
Try navigating to /usr/local/bin and : if check if the file named ng is present over there, if yes then rm -r ng...
Read more >
Unable to install angular cli through npm · Issue #5296 - GitHub
Open your command prompt with administrative privileges and uninstall angular/cli by using npm uninstall -g angular-cli command. · Remove ...
Read more >
Angular CLI - npm
CLI tool for Angular. Latest version: 15.0.4, last published: 13 days ago. Start using @angular/cli in your project by running `npm i ...
Read more >
Can not Install angular-cli?Here is how to Do it....!!! - YouTube
Hey whats up guys this is tech mad 07 ... to day I am gonna show you how to install angular cli if...
Read more >
How to Solve the Angular NPM Error - C# Corner
The error in NPM, 'error package install failed, see above', can occur when the user creates a new project in Angular using Node.js...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found