Nativescript install error: trying old xmlbuilder version? - nativescript

I'm trying to install nativescript on Windows 10 using Node 4.5.0 and am getting an error. Apparently it's trying to install version 2.2.1 of xmlbuilder (from 2014) which requires node 0.8 or 0.10.
From what I can see it's trying to install an npm node module? I don't know how to debug what's going on. Could it be something to do with nvm?
58355 info install write-file-atomic#1.1.4
58356 info postinstall write-file-atomic#1.1.4
58357 info install npm#2.15.9
58358 info postinstall npm#2.15.9
58359 verbose unlock done using C:\Users\Jason\AppData\Roaming\npm-cache\_locks\npm-2b9ada4a148d9bea.lock for C:\Program Files\nodejs\node_modules\nativescript\node_modules\npm
58360 verbose about to build C:\Program Files\nodejs\node_modules\nativescript
58361 verbose unlock done using C:\Users\Jason\AppData\Roaming\npm-cache\_locks\nativescript-a3c660f576f1098e.lock for C:\Program Files\nodejs\node_modules\nativescript
58362 verbose stack Error: Unsupported
58362 verbose stack at checkEngine (C:\Users\Jason\AppData\Roaming\nvm\v4.5.0\node_modules\npm\node_modules\npm-install-checks\index.js:16:16)
58362 verbose stack at Array.<anonymous> (C:\Users\Jason\AppData\Roaming\nvm\v4.5.0\node_modules\npm\node_modules\slide\lib\bind-actor.js:15:8)
58362 verbose stack at LOOP (C:\Users\Jason\AppData\Roaming\nvm\v4.5.0\node_modules\npm\node_modules\slide\lib\chain.js:15:14)
58362 verbose stack at chain (C:\Users\Jason\AppData\Roaming\nvm\v4.5.0\node_modules\npm\node_modules\slide\lib\chain.js:20:5)
58362 verbose stack at C:\Users\Jason\AppData\Roaming\nvm\v4.5.0\node_modules\npm\lib\install.js:1038:5
58362 verbose stack at C:\Users\Jason\AppData\Roaming\nvm\v4.5.0\node_modules\npm\lib\utils\locker.js:39:7
58362 verbose stack at cb (C:\Users\Jason\AppData\Roaming\nvm\v4.5.0\node_modules\npm\node_modules\lockfile\lockfile.js:149:38)
58362 verbose stack at C:\Users\Jason\AppData\Roaming\nvm\v4.5.0\node_modules\npm\node_modules\lockfile\lockfile.js:171:16
58362 verbose stack at C:\Users\Jason\AppData\Roaming\nvm\v4.5.0\node_modules\npm\node_modules\graceful-fs\graceful-fs.js:43:10
58362 verbose stack at FSReqWrap.oncomplete (fs.js:82:15)
58363 verbose pkgid xmlbuilder#2.2.1
58364 verbose cwd C:\Users\Jason
58365 error Windows_NT 10.0.10586
58366 error argv "C:\\Program Files\\nodejs\\node.exe" "C:\\Program Files\\nodejs\\node_modules\\npm\\bin\\npm-cli.js" "i" "-g" "nativescript"
58367 error node v4.5.0
58368 error npm v2.15.9
58369 error code ENOTSUP
58370 error notsup Unsupported
58370 error notsup Not compatible with your version of node/npm: xmlbuilder#2.2.1
58370 error notsup Required: {"node":"0.8.x || 0.10.x"}
58370 error notsup Actual: {"npm":"2.15.9","node":"4.5.0"}
58371 verbose exit [ 1, true ]

I have the same setup (Win-10 with node.js 4.5 and npm 2.15.9) and everything is working as expected - the NativeScript is installing from npm with no hassle.
You can try this windows node manager in order to exclude a local incompatibility with node version. With nvm you can install several nodejs version and swith within them.
For example:
nvm install 4.4.7
Will install the previous stable version and with nvm use 4.4.7 you can try to install nativescritp again and see if the error is still present.
You can also try
npm cache clean
Which will clean your entire npm cache as discussed here.

Related

Laravel NPM fixing cross-env problem leading to problem 'enoent spawn bash ENOENT'

I've been struggling to fix the common 'cross-env' is not recognized as an internal or external command, problem with NPM in a Laravel 9.x project on a Windows 10 machine. I've gone over most of the other similar topics but I can't find a solution that works and I'm not familiar with yarn which is what a lot of the answers involve.
npm install -g cross-env was used but trying to run NPM then gave a path error:
> development
> cross-env NODE_ENV=development node_modules/webpack/bin/webpack.js --progress --hide-mde_modules/laravel-mix/setup/webpack.config.js
The system cannot find the path specified.
node:events:491
throw er; // Unhandled 'error' event
^
Error: spawn node_modules\webpack\bin\webpack.js ENOENT
at notFoundError (C:\Users\Tobias\AppData\Roaming\npm\node_modules\cross-env\node_molib\enoent.js:6:26)
at verifyENOENT (C:\Users\Tobias\AppData\Roaming\npm\node_modules\cross-env\node_modib\enoent.js:40:16)
at cp.emit (C:\Users\Tobias\AppData\Roaming\npm\node_modules\cross-env\node_modules\oent.js:27:25)
Emitted 'error' event on ChildProcess instance at:
at cp.emit (C:\Users\Tobias\AppData\Roaming\npm\node_modules\cross-env\node_modules\cross-spawn\lib\enoent.js:30:37)
at ChildProcess._handle.onexit (node:internal/child_process:291:12) {
code: 'ENOENT',
errno: 'ENOENT',
path: 'node_modules\\webpack\\bin\\webpack.js',
spawnargs: [
'--progress',
'--hide-modules',
'--config=node_modules/laravel-mix/setup/webpack.config.js'
]
}
Node.js v18.12.1`
To solve this I used the command npm config set script-shell bash as suggested here
But this then gives a 'NOENT' problem that I can't find a good solution for to fix (or revert back)
> development
> cross-env NODE_ENV=development node_modules/webpack/bin/webpack.js --progress --hide-modules --config=node_modules/laravel-m
npm ERR! code ENOENT
npm ERR! syscall spawn bash
npm ERR! path C:\xampp\htdocs\antheap
npm ERR! errno -4058
npm ERR! enoent spawn bash ENOENT
npm ERR! enoent This is related to npm not being able to find a file.
npm ERR! enoent
npm ERR! A complete log of this run can be found in:
npm ERR! C:\Users\Tobias\AppData\Local\npm-cache\_logs\2022-12-22T09_34_44_288Z-debug-0.log
here is the logfile
0 verbose cli C:\Program Files\nodejs\node.exe C:\Users\Tobias\AppData\Roaming\npm\node_modules\npm\bin\npm-cli.js
1 info using npm#8.11.0
2 info using node#v18.12.1
3 timing npm:load:whichnode Completed in 1ms
4 timing config:load:defaults Completed in 2ms
5 timing config:load:file:C:\Users\Tobias\AppData\Roaming\npm\node_modules\npm\npmrc Completed in 3ms
6 timing config:load:builtin Completed in 3ms
7 timing config:load:cli Completed in 1ms
8 timing config:load:env Completed in 1ms
9 timing config:load:file:C:\xampp\htdocs\antheap\.npmrc Completed in 0ms
10 timing config:load:project Completed in 2ms
11 timing config:load:file:C:\Users\Tobias\.npmrc Completed in 0ms
12 timing config:load:user Completed in 0ms
13 timing config:load:file:C:\Users\Tobias\AppData\Roaming\npm\etc\npmrc Completed in 0ms
14 timing config:load:global Completed in 0ms
15 timing config:load:validate Completed in 1ms
16 timing config:load:credentials Completed in 0ms
17 timing config:load:setEnvs Completed in 1ms
18 timing config:load Completed in 12ms
19 timing npm:load:configload Completed in 12ms
20 timing npm:load:mkdirpcache Completed in 1ms
21 timing npm:load:mkdirplogs Completed in 0ms
22 verbose title npm run development
23 verbose argv "run" "development"
24 timing npm:load:setTitle Completed in 1ms
25 timing config:load:flatten Completed in 2ms
26 timing npm:load:display Completed in 3ms
27 verbose logfile logs-max:10 dir:C:\Users\Tobias\AppData\Local\npm-cache\_logs
28 verbose logfile C:\Users\Tobias\AppData\Local\npm-cache\_logs\2022-12-22T09_34_44_288Z-debug-0.log
29 timing npm:load:logFile Completed in 15ms
30 timing npm:load:timers Completed in 0ms
31 timing npm:load:configScope Completed in 0ms
32 timing npm:load Completed in 34ms
33 silly logfile start cleaning logs, removing 2 files
34 timing command:run Completed in 8ms
35
35 verbose stack at ChildProcess._handle.onexit (node:internal/child_process:283:19)
35 verbose stack at onErrorNT (node:internal/child_process:476:16)
35 verbose stack at process.processTicksAndRejections (node:internal/process/task_queues:82:21)
36 verbose cwd C:\xampp\htdocs\antheap
37 verbose Windows_NT 10.0.19044
38 verbose node v18.12.1
39 verbose npm v8.11.0
40 error code ENOENT
41 error syscall spawn bash
42 error path C:\xampp\htdocs\antheap
43 error errno -4058
44 error enoent spawn bash ENOENT
45 error enoent This is related to npm not being able to find a file.
45 error enoent
46 verbose exit -4058
47 timing npm Completed in 54ms
48 verbose code -4058
49 error A complete log of this run can be found in:
49 error C:\Users\Tobias\AppData\Local\npm-cache\_logs\2022-12-22T09_34_44_288Z-debug-0.log
I saw a suggesting to use npm ci but this didn't work. I've also reinstalled Node.js, and ran npm install, both to no effect.
Deleting and reinstalling NPM within the app doesn't help either. I also show a host of other possible issues (like the old lock file which it however never seems to update properly),
PS C:\xampp\htdocs\antheap> npm install
npm WARN old lockfile
npm WARN old lockfile The package-lock.json file was created with an old version of npm,
npm WARN old lockfile so supplemental metadata must be fetched from the registry.
npm WARN old lockfile
npm WARN old lockfile This is a one-time fix-up, please be patient...
npm WARN old lockfile
npm WARN deprecated har-validator#5.1.3: this library is no longer supported
npm WARN deprecated chokidar#2.1.6: Chokidar 2 does not receive security updates since 2019. Upgrade to chokidar 3 with 15x fewer dependencies
npm WARN deprecated browserslist#2.11.3: Browserslist 2 could fail on reading Browserslist >3.0 config used in other tools.
npm WARN deprecated debug#4.1.1: Debug versions >=3.2.0 <3.2.7 || >=4 <4.3.1 have a low-severity ReDos regression when used in a Node.js environment. It is recommended you upgrade to 3.2.7 or 4.3.1. (https://github.com/visionmedia/debug/issues/797)
npm WARN deprecated debug#4.1.1: Debug versions >=3.2.0 <3.2.7 || >=4 <4.3.1 have a low-severity ReDos regression when used in a Node.js environment. It is recommended you upgrade to 3.2.7 or 4.3.1. (https://github.com/visionmedia/debug/issues/797)
npm WARN deprecated urix#0.1.0: Please see https://github.com/lydell/urix#deprecated
npm WARN deprecated extract-text-webpack-plugin#3.0.2: Deprecated. Please use https://github.com/webpack-contrib/mini-css-extract-plugin
npm WARN deprecated resolve-url#0.2.1: https://github.com/lydell/resolve-url#deprecated
npm WARN deprecated source-map-url#0.4.0: See https://github.com/lydell/source-map-url#deprecated
npm WARN deprecated flatten#1.0.2: flatten is deprecated in favor of utility frameworks such as lodash.
npm WARN deprecated request#2.88.2: request has been deprecated, see https://github.com/request/request/issues/3142
npm WARN deprecated source-map-resolve#0.5.2: See https://github.com/lydell/source-map-resolve#deprecated
npm WARN deprecated uuid#3.3.2: Please upgrade to version 7 or higher. Older versions may use Math.random() in certain circumstances, which is known to be problematic. See https://v8.dev/blog/math-random for details.
npm WARN deprecated querystring#0.2.0: The querystring API is considered Legacy. new code should use the URLSearchParams API instead.
npm WARN deprecated acorn-dynamic-import#2.0.2: This is probably built in to whatever tool you're using. If you still need it... idk
npm WARN deprecated browserslist#1.7.7: Browserslist 2 could fail on reading Browserslist >3.0 config used in other tools.
npm WARN deprecated uglify-es#3.3.9: support for ECMAScript is superseded by `uglify-js` as of v3.13.0
npm WARN deprecated mkdirp#0.5.1: Legacy versions of mkdirp are no longer supported. Please update to mkdirp 1.x. (Note that the API surface has changed to use Promises in 1.x.)
npm WARN deprecated browserslist#1.7.7: Browserslist 2 could fail on reading Browserslist >3.0 config used in other tools.
npm WARN deprecated browserslist#1.7.7: Browserslist 2 could fail on reading Browserslist >3.0 config used in other tools.
npm WARN deprecated axios#0.18.1: Critical security vulnerability fixed in v0.21.1. For more information, see https://github.com/axios/axios/pull/3410
npm WARN deprecated popper.js#1.15.0: You can find the new Popper v2 at #popperjs/core, this package is dedicated to the legacy v1
npm WARN deprecated buffer#4.9.1: This version of 'buffer' is out-of-date. You must update to v4.9.2 or newer
npm WARN deprecated svgo#0.7.2: This SVGO version is no longer supported. Upgrade to v2.x.x.
npm WARN deprecated tar#2.2.2: This version of tar is no longer supported, and will not receive security updates. Please upgrade asap.
npm WARN deprecated core-js#2.6.9: core-js#<3.23.3 is no longer maintained and not recommended for usage due to the number of issues. Because of the V8 engine whims, feature detection in old core-js versions could cause a slowdown up to 100x even if nothing is polyfilled. Some versions have web compatibility issues. Please, upgrade your dependencies to the actual version of core-js.
npm ERR! code ENOENT
npm ERR! syscall spawn bash
npm ERR! path C:\xampp\htdocs\antheap\node_modules\node-sass
npm ERR! errno -4058
npm ERR! enoent spawn bash ENOENT
npm ERR! enoent This is related to npm not being able to find a file.
npm ERR! enoent
npm ERR! A complete log of this run can be found in:
npm ERR! C:\Users\Tobias\AppData\Local\npm-cache\_logs\2022-12-22T09_52_52_967Z-debug-0.log

npm ERR! No git binary found in $PATH

I can't seem to get zenbot to install I am new to node.js, so please be kind. I am getting all kinds of error I do have git installed. I followed the install instructions and I really don't know where to start. I am a Java and C programming trying to cut my teeth on something new and learn through the bumps and bruises.
C:\zenbot>npm install
npm ERR! code ENOGIT
npm ERR! No git binary found in $PATH
npm ERR!
npm ERR! Failed using git.
npm ERR! Please check if you have git installed and in your PATH.
npm ERR! A complete log of this run can be found in:
npm ERR! C:\Users\\AppData\Roaming\npm-cache\_logs\2017-12-25T08_17_27_513Z-debug.log
----- Log file--
0 info it worked if it ends with ok
1 verbose cli [ 'C:\\nodejs\\node.exe',
1 verbose cli 'C:\\nodejs\\node_modules\\npm\\bin\\npm-cli.js',
1 verbose cli 'install' ]
2 info using npm#5.5.1
3 info using node#v8.9.3
4 verbose npm-session 5167d752483581f2
5 silly install runPreinstallTopLevelLifecycles
6 silly preinstall zenbot4#4.0.5
7 info lifecycle zenbot4#4.0.5~preinstall: zenbot4#4.0.5
8 silly install loadCurrentTree
9 silly install readLocalPackageData
10 silly install loadIdealTree
11 silly install cloneCurrentTreeToIdealTree
12 silly install loadShrinkwrap
13 silly fetchPackageMetaData error for forex.analytics#github:mkmarek/forex.analytics#7bc278987700d4204e959af17de61495941d1a14 No git binary found in $PATH
14 verbose stack Error: No git binary found in $PATH
14 verbose stack at checkGit (C:\nodejs\node_modules\npm\node_modules\pacote\lib\util\git.js:199:17)
14 verbose stack at spawnGit (C:\nodejs\node_modules\npm\node_modules\pacote\lib\util\git.js:178:10)
14 verbose stack at pinflight (C:\nodejs\node_modules\npm\node_modules\pacote\lib\util\git.js:110:12)
14 verbose stack at C:\nodejs\node_modules\npm\node_modules\promise-inflight\inflight.js:29:24
14 verbose stack at Promise._execute (C:\nodejs\node_modules\npm\node_modules\bluebird\js\release\debuggability.js:300:9)
14 verbose stack at Promise._resolveFromExecutor (C:\nodejs\node_modules\npm\node_modules\bluebird\js\release\promise.js:483:18)
14 verbose stack at new Promise (C:\nodejs\node_modules\npm\node_modules\bluebird\js\release\promise.js:79:10)
14 verbose stack at _inflight (C:\nodejs\node_modules\npm\node_modules\promise-inflight\inflight.js:28:25)
14 verbose stack at C:\nodejs\node_modules\npm\node_modules\promise-inflight\inflight.js:22:14
14 verbose stack at tryCatcher (C:\nodejs\node_modules\npm\node_modules\bluebird\js\release\util.js:16:23)
14 verbose stack at Promise._settlePromiseFromHandler (C:\nodejs\node_modules\npm\node_modules\bluebird\js\release\promise.js:512:31)
14 verbose stack at Promise._settlePromise (C:\nodejs\node_modules\npm\node_modules\bluebird\js\release\promise.js:569:18)
14 verbose stack at Promise._settlePromiseCtx (C:\nodejs\node_modules\npm\node_modules\bluebird\js\release\promise.js:606:10)
14 verbose stack at Async._drainQueue (C:\nodejs\node_modules\npm\node_modules\bluebird\js\release\async.js:138:12)
14 verbose stack at Async._drainQueues (C:\nodejs\node_modules\npm\node_modules\bluebird\js\release\async.js:143:10)
14 verbose stack at Immediate.Async.drainQueues (C:\nodejs\node_modules\npm\node_modules\bluebird\js\release\async.js:17:14)
15 verbose cwd C:\zenbot
16 verbose Windows_NT 10.0.15063
17 verbose argv "C:\\nodejs\\node.exe" "C:\\nodejs\\node_modules\\npm\\bin\\npm-cli.js" "install"
18 verbose node v8.9.3
19 verbose npm v5.5.1
20 error code ENOGIT
21 error No git binary found in $PATH
22 error Failed using git.
22 error Please check if you have git installed and in your PATH.
23 verbose exit [ 1, true ]
C:\WINDOWS\system32>git -v Unknown option: -v usage: git [--version] [--help] [-C <path>] [-c name=value] [--exec-path[=<path>]] [--html-path] [--man-path] [--info-path] [-p | --paginate | --no-pager] [--no-replace-objects] [--bare] [--git-dir=<path>] [--work-tree=<path>] [--namespace=<name>] <command> [<args>] –
You are trying within C:\WINDOWS\system32, probably git executable is available over there.
Change the directory to C:\ and then try git --version.
If you get error git is not recognized..., then git path is not set in environment variables.
So, open your environment variable settings and set the git executable path to PATH variable.
Looks like it's missing from the alpine image.
npm install is kinda fundamental to node and git is required to install certain dependencies.
Including
RUN apk update && apk upgrade && \
apk add --no-cache git
in the dockerfile will fix it.
While running RUN npm install --progress=false --unsafe-perm in docker file on jenkins
FROM node:10.15.0-alpine (as the base image)
I was getting npm ERR! No git binary found in $PATH
Solution- added below line in docker file and it worked
RUN apk update && apk upgrade &&
apk add --no-cache git

Installation LoopBack-CLI error node-gyp rebuild

Hi Im installing the loopback-cli.
Running these commands:
npm install --global --production windows-build-tools
AND
npm install -g loopback-cli
The second command run rebuilding the ursa module into error. There is some link to C:\OpenSSL-Win64. What the ... is this? Some hardcoded library link?
Write me please some way how to install normally the loopback. This is from their installation site. Thanx.
Here the log:
C:\Users\Erik\AppData\Roaming\npm\node_modules\loopback-cli\node_modules\ursa>if not defined npm_config_node_gyp (node "C:\nodejs\node_modules\npm\bin\node-gyp-bin\\..\..\node_modules\node-gyp\bin\node-gyp.js" rebuild ) else (node "" rebuild )
Building the projects in this solution one at a time. To enable parallel build, please add the "/m" switch.
ursaNative.cc
win_delay_load_hook.cc
..\src\ursaNative.cc(157): warning C4244: 'argument': conversion from 'ssize_t' to 'int', possible loss of data [C:\Use
rs\Erik\AppData\Roaming\npm\node_modules\loopback-cli\node_modules\ursa\build\ursaNative.vcxproj]
..\src\ursaNative.cc(172): warning C4244: 'argument': conversion from 'ssize_t' to 'int', possible loss of data [C:\Use
rs\Erik\AppData\Roaming\npm\node_modules\loopback-cli\node_modules\ursa\build\ursaNative.vcxproj]
LINK : fatal error LNK1181: cannot open input file 'C:\OpenSSL-Win64\lib\libeay32.lib' [C:\Users\Erik\AppData\Roaming\n
pm\node_modules\loopback-cli\node_modules\ursa\build\ursaNative.vcxproj]
gyp ERR! build error
gyp ERR! stack Error: `C:\Program Files (x86)\MSBuild\14.0\bin\msbuild.exe` failed with exit code: 1
gyp ERR! stack at ChildProcess.onExit (C:\nodejs\node_modules\npm\node_modules\node-gyp\lib\build.js:258:23)
gyp ERR! stack at emitTwo (events.js:126:13)
gyp ERR! stack at ChildProcess.emit (events.js:214:7)
gyp ERR! stack at Process.ChildProcess._handle.onexit (internal/child_process.js:198:12)
gyp ERR! System Windows_NT 10.0.15063
gyp ERR! command "C:\\nodejs\\node.exe" "C:\\nodejs\\node_modules\\npm\\node_modules\\node-gyp\\bin\\node-gyp.js" "rebuild"
gyp ERR! cwd C:\Users\Erik\AppData\Roaming\npm\node_modules\loopback-cli\node_modules\ursa
gyp ERR! node -v v8.9.0
gyp ERR! node-gyp -v v3.6.2
gyp ERR! not ok
npm WARN optional SKIPPING OPTIONAL DEPENDENCY: ursa#0.9.4 (node_modules\loopback-cli\node_modules\ursa):
npm WARN optional SKIPPING OPTIONAL DEPENDENCY: ursa#0.9.4 install: `node-gyp rebuild`
npm WARN optional SKIPPING OPTIONAL DEPENDENCY: Exit status 1
+ loopback-cli#4.0.0
added 3 packages and updated 1 package in 27.638s
Same issue here.
Setup before fixing:
lb -v 4.2.1 (generator-loopback#5.9.4 loopback-workspace#4.5.0)
node -v v10.13.0
OS: Windows 10 Home
I was able to fix the issue after taking the following steps:
Install node v8.12.0
Install OpenSSL 1.1 in C:\OpenSSL-Win64 (strong-ursa hard codes the location)
Create a symbolic link in C:\OpenSSL-Win64\lib named libeay64.lib which targets libcrypto.lib.
Run npm i -g windows-build-tools
Run npm i -g looback-cli again.
I'm not sure if rolling back the NodeJS version to 8.12 is necessary. There are a few widely, albeit not well documented pain points working with Loopback due to strong-ursa's use of native libraries. (Please note, this is unconfirmed information as I'm in a hurry to get back to developing the project at hand.) These steps allowed me to continue using Loopback CLI unhindered.
Useful links:
Download previous NodeJS releases: https://nodejs.org/en/download/releases/
Download OpenSSL: https://slproweb.com/products/Win32OpenSSL.html
windows-build-tools: https://github.com/felixrieseberg/windows-build-tools
https://github.com/curl/curl/issues/984
https://github.com/strongloop/loopback-cli/issues/36#issuecomment-434331508

With Node 0.12.2 and npm 2.7.4 ionic installation error on windows 7

I am downloaded the node installation file "node-v0.12.2-x64.msi" for 64 bit windows 7 OS. All node and npm commands are working fine. I checked both the node and npm versions.
But when I try to install ionic by the following command:
npm install -g cordova ionic
Its gives me the following error:
npm WARN engine cordova-js#3.9.0: wanted: {"node":"~0.10.x"} (current: {"node":"
0.12.2","npm":"2.7.4"})
npm WARN engine npm#1.3.4: wanted: {"node":">=0.6","npm":"1"} (current: {"node":
"0.12.2","npm":"2.7.4"})
npm WARN engine xmlbuilder#2.2.1: wanted: {"node":"0.8.x || 0.10.x"} (current: {
"node":"0.12.2","npm":"2.7.4"})
npm WARN installMany normalize-package-data was bundled with npm#1.3.4, but bund
led package wasn't found in unpacked tree
npm ERR! tar.unpack untar error C:\Users\Biswarup\AppData\Local\Temp\npm-1484-8b
f97a1e\registry.npmjs.org\request\-\request-2.9.203.tgz
npm ERR! cb() never called!
Biswarup is my username in above all cases.
I check the following links for troubleshooting, but nothing works for me.
https://github.com/npm/npm/wiki/Troubleshooting#error-enoent-stat-cusersuserappdataroamingnpm-on-windows-7
https://github.com/diegonetto/generator-ionic/issues/42
Please guide me, I am totally stuck at that point. Try to removing node js and reinstalling it many times. But nothing goes right.
First of all packages warning you, that it requires nodejs 0.10.x and may be that is a reason.
Another try you can upgrade npm and try to found new version. So here steps to do it:
npm cache clean
npm update -g npm
npm cache clean
Please download Node 0.10.38
I was too having problem with newer version of node.
I have already aswered this in detail https://stackoverflow.com/a/31124491/1276616

"npm faq" fails on Windows 7 ("spawn ENOENT" errors)

I have installed node.js on Windows 7 with their latest installer. It seemed to work, I can call npm and node from the console (either cmd or PowerShell), but I keep getting errors.
There are a lot of questions here about node.js on windows, but they all mention some specific piece of code. I'm getting the "spawn ENOENT" with a lot of simple commands, for instance yo, if I then pick "update generators" :
events.js:72
throw er; // Unhandled 'error' event
^
Error: spawn ENOENT
at errnoException (child_process.js:988:11)
at Process.ChildProcess._handle.onexit (child_process.js:779:34)
even npm faq fails :
PS E:\www\something> npm faq
npm ERR! Error: spawn ENOENT
npm ERR! at errnoException (child_process.js:988:11)
npm ERR! at Process.ChildProcess._handle.onexit (child_process.js:779:34)
npm ERR! If you need help, you may report this *entire* log,
npm ERR! including the npm and node versions, at:
npm ERR! <http://github.com/isaacs/npm/issues>
It seems that the problem is that node uses unix command names like dir, which do not exist on Windows. Some blog posts mention using Cygwin, but mostly for building node.js, not for calling it. The official nodejs website doesn't mention that cygwin is a prerequisite, either.
Here's the npm-debug.log :
0 info it worked if it ends with ok
1 verbose cli [ 'C:\\Program Files\\nodejs\\\\node.exe',
1 verbose cli 'C:\\Program Files\\nodejs\\node_modules\\npm\\bin\\npm-cli.js',
1 verbose cli 'faq' ]
2 info using npm#1.3.24
3 info using node#v0.10.25
4 verbose node symlink C:\Program Files\nodejs\\node.exe
5 error Error: spawn ENOENT
5 error at errnoException (child_process.js:988:11)
5 error at Process.ChildProcess._handle.onexit (child_process.js:779:34)
6 error If you need help, you may report this *entire* log,
6 error including the npm and node versions, at:
6 error <http://github.com/isaacs/npm/issues>
7 error System Windows_NT 6.1.7601
8 error command "C:\\Program Files\\nodejs\\\\node.exe" "C:\\Program Files\\nodejs\\node_modules\\npm\\bin\\npm-cli.js" "faq"
9 error cwd E:\
10 error node -v v0.10.25
11 error npm -v 1.3.24
12 error syscall spawn
13 error code ENOENT
14 error errno ENOENT
15 verbose exit [ 1, true ]
Make sure that you have c:\Windows\System32 on your 'Path' System Variable. I was having this exact problem and this was the fix I needed. I must have taken it out in error sometime in the past.

Resources