Hello I am unable deo deploy a firebase app after upgrading to node 10.
This is the log output.
What is wrong ?
I have upgraded firebase tools as well
10 silly lifecycle functions#~deploy: Args: [ '-c', 'firebase deploy --only functions' ]
11 silly lifecycle functions#~deploy: Returned: code: 1 signal: null
12 info lifecycle functions#~deploy: Failed to exec deploy script
13 verbose stack Error: functions# deploy: `firebase deploy --only functions`
13 verbose stack Exit status 1
13 verbose stack at EventEmitter.<anonymous>
(/usr/local/Cellar/nvm/0.35.3/versions/node/v10.0.0/lib/node_modules/npm/node_modules/npm-
lifecycle/index.js:285:16)
13 verbose stack at EventEmitter.emit (events.js:182:13)
13 verbose stack at ChildProcess.<anonymous>
(/usr/local/Cellar/nvm/0.35.3/versions/node/v10.0.0/lib/node_modules/npm/node_modules/npm-
lifecycle/lib/spawn.js:55:14)
13 verbose stack at ChildProcess.emit (events.js:182:13)
13 verbose stack at maybeClose (internal/child_process.js:947:16)
13 verbose stack at Process.ChildProcess._handle.onexit
(internal/child_process.js:236:5)
14 verbose pkgid functions#
15 verbose cwd /Users/Sites/teambox-firebase/functions
16 verbose Darwin 17.7.0
17 verbose argv "/usr/local/Cellar/nvm/0.35.3/versions/node/v10.0.0/bin/node"
"/usr/local/opt/nvm/versions/node/v10.0.0/bin/npm" "run" "deploy"
18 verbose node v10.0.0
19 verbose npm v5.6.0
20 error code ELIFECYCLE
21 error errno 1
22 error functions# deploy: `firebase deploy --only functions`
22 error Exit status 1
23 error Failed at the functions# deploy script.
23 error This is probably not a problem with npm. There is likely additional logging output
above.
24 verbose exit [ 1, true ]
You are using a somewhat old version of node, or there is some misconfiguration. It appears you are using nvm, so I would strongly suggest updating node with nvm install 10 if you wish to stick to node 10. Be sure to close any open command shells and restart.
When trying to hit the command : npm install -g #angular/cli#6.1.1
Note:
I have Node.Js LTS 10.xx version, .Net Framework 4.7.2 Developer pack, and all necessary extensions in place.
Error thrown:
npm ERR! code ELOOP
npm ERR! syscall stat
npm ERR! path \\horofs**\users$\
npm ERR! errno -62
npm ERR! ELOOP: too many symbolic links encountered, stat '\\horofs06\users$\'
npm ERR! A complete log of this run can be found in:
npm ERR! \\horofs**\users$\W****\AppData\Roaming\npm-cache\_logs\2020-07-31T13_26_25_468Z-debug.log
The log states this:
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 'install',
1 verbose cli '-g',
1 verbose cli '#angular/cli#6.1.1' ]
2 info using npm#6.14.6
3 info using node#v10.22.0
4 verbose npm-session 8b2e687260b66580
5 silly install loadCurrentTree
6 silly install readGlobalPackageData
7 http fetch GET 200 https://registry.npmjs.org/#angular%2fcli 282ms (from cache)
8 silly pacote version manifest for #angular/cli#6.1.1 fetched in 426ms
9 verbose stack Error: ELOOP: too many symbolic links encountered, stat '\\horofs**\users$\'
9 verbose stack at eloop (C:\Program Files\nodejs\node_modules\npm\node_modules\read-package-tree\realpath.js:58:17)
9 verbose stack at realpathCached (C:\Program Files\nodejs\node_modules\npm\node_modules\read-package-tree\realpath.js:19:11)
9 verbose stack at realpathCached (C:\Program Files\nodejs\node_modules\npm\node_modules\read-package-tree\realpath.js:39:10)
9 verbose stack at realpathCached (C:\Program Files\nodejs\node_modules\npm\node_modules\read-package-tree\realpath.js:39:10)
9 verbose stack at realpathCached (C:\Program Files\nodejs\node_modules\npm\node_modules\read-package-tree\realpath.js:39:10)
9 verbose stack at realpathCached (C:\Program Files\nodejs\node_modules\npm\node_modules\read-package-tree\realpath.js:39:10)
9 verbose stack at realpathCached (C:\Program Files\nodejs\node_modules\npm\node_modules\read-package-tree\realpath.js:39:10)
9 verbose stack at realpathCached (C:\Program Files\nodejs\node_modules\npm\node_modules\read-package-tree\realpath.js:39:10)
9 verbose stack at realpathCached (C:\Program Files\nodejs\node_modules\npm\node_modules\read-package-tree\realpath.js:39:10)
9 verbose stack at realpathCached (C:\Program Files\nodejs\node_modules\npm\node_modules\read-package-tree\realpath.js:39:10)
9 verbose stack at realpathCached (C:\Program Files\nodejs\node_modules\npm\node_modules\read-package-tree\realpath.js:39:10)
9 verbose stack at realpathCached (C:\Program Files\nodejs\node_modules\npm\node_modules\read-package-tree\realpath.js:39:10)
9 verbose stack at realpathCached (C:\Program Files\nodejs\node_modules\npm\node_modules\read-package-tree\realpath.js:39:10)
9 verbose stack at realpathCached (C:\Program Files\nodejs\node_modules\npm\node_modules\read-package-tree\realpath.js:39:10)
9 verbose stack at realpathCached (C:\Program Files\nodejs\node_modules\npm\node_modules\read-package-tree\realpath.js:39:10)
9 verbose stack at realpathCached (C:\Program Files\nodejs\node_modules\npm\node_modules\read-package-tree\realpath.js:39:10)
10 verbose cwd C:\Cqe\Periscope\src\Periscope\Endava.Periscope.Web
11 verbose Windows_NT 6.3.9600
12 verbose argv "C:\\Program Files\\nodejs\\node.exe" "C:\\Program Files\\nodejs\\node_modules\\npm\\bin\\npm-cli.js" "install" "-g" "#angular/cli#6.1.1"
13 verbose node v10.22.0
14 verbose npm v6.14.6
15 error code ELOOP
Please help me.
I met a similar issue and the log said as following,
error ELOOP: too many symbolic links encountered, chmod '/Users/myname/projects/my-electron-app/node_modules/electron/cli.js'
error ELOOP: too many symbolic links encountered, open '/Users/myname/projects/my-electron-app/node_modules/electron/npm-shrinkwrap.json'
When I checked my folder and found the folder electron link to itself, so it led to a never-ending loop.
lrwxr-xr-x 1 myname staff 8 Feb 20 11:42 electron# -> electron
I checked the size and directly removed the file, then used npm install electron again. It finally worked.
So please check the link, it looks that the file in your application links to itself too.
I doubt that it should be an issue about npm because npm tries to create a link before the file is actually downloaded.
You can judge for yourself below. The disappointing situation is that you may not be able to use NodeJS when your User data is stored in a folder with more than 2,000 subfolders.
Like you, my User folder is stored on a network drive instead of C:
In "readGlobalPackageData()," the value of self.where is passed to readPackageTree. In my case, self.where = "\[domain]\users$[office location][userID]\AppData\npm." Code in realpathCached() is backing out of that path and trying to read all subfolders as it goes. When it gets to "\[domain]\users$", the "ELOOP" error is logged because there's a max depth of 2000, and my company's Users folder has more than 25,000 subfolders.
Here are two possible solutions:
First, remove -g from the install command to make the install local to the folder for your new app. The downside is that if there's an update to one of the dependencies, you'll have to install it manually everywhere you didn't use -g. That can be good if an update contains breaking changes.
Second, and I don't recommend this solution, is to edit one of the installer files. The installer is reading all the ID folders in your User folder and it's only failing because an arbitrary limits was reached. If you increase the limit, the error should go away but you're also letting the script read all the user IDs on your network. Try this at your own risk.
Open this file:
C:\Program Files\nodejs\node_modules\npm\node_modules\read-package-tree\realpath.js.
On line 18, "if (depth > 2000)," change 2000 to a number greater than the number of folders under your users$ (share) folder.
As answered by Classic Craig
You can judge for yourself below. The disappointing situation is that you may not be able to use NodeJS when your User data is stored in a folder with more than 2,000 subfolders. Like you, my User folder is stored on a network drive instead of C: In "readGlobalPackageData()," the value of self.where is passed to readPackageTree. In my case, self.where = "[domain]\users$[office location][userID]\AppData\npm." Code in realpathCached() is backing out of that path and trying to read all subfolders as it goes. When it gets to "[domain]\users$", the "ELOOP" error is logged because there's a max depth of 2000, and my company's Users folder has more than 25,000 subfolders.
I also cannot install Angular globally on my user folder on my company's mainframe. I work around this by installing it locally.
First I initialized the installation location with
npm init
and by going to the directory within the node_modules I accessed .bin folder
cd ../node_modules/.bin
The ng command can be run within the .bin folder. Then I used ng new to create a new project within the .bin folder. Then, I can use the
npm run ng <command>
here. So I can use the ng command within the project folder.
I'm using jade-cli to compile my project from .jade files into .html.
Jade files have following hierarchy:
components
views
templates
...
I want rendered result to have same folder structure and trying to use -H attribute as it is said in documentation here: https://www.npmjs.com/package/jade-cli
However when I'm using command jade -P -H src -o dst npm returns following error:
silly lifecycle #~build: Args: [ '/d /s /c', 'jade -P -H src -o dst' ]
12 silly lifecycle #~build: Returned: code: 1 signal: null
info lifecycle #~build: Failed to exec build script
verbose stack Error: # build: `jade -P -H src -o dst`
verbose stack Exit status 1
verbose stack at EventEmitter.<anonymous> (C:\Program Files\nodejs\node_modules\npm\lib\utils\lifecycle.js:255:16)
verbose stack at emitTwo (events.js:106:13)
verbose stack at EventEmitter.emit (events.js:191:7)
verbose stack at ChildProcess.<anonymous> (C:\Program Files\nodejs\node_modules\npm\lib\utils\spawn.js:40:14)
verbose stack at emitTwo (events.js:106:13)
verbose stack at ChildProcess.emit (events.js:191:7)
verbose stack at maybeClose (internal/child_process.js:877:16)
verbose stack at Process.ChildProcess._handle.onexit (internal/child_process.js:226:5)
error Windows_NT 6.1.7601
error argv "C:\\Program Files\\nodejs\\node.exe" "C:\\Program Files\\nodejs\\node_modules\\npm\\bin\\npm-cli.js" "run" "build"
error node v6.9.1
error npm v3.10.8
error code ELIFECYCLE
error # build: `jade -P -H src -o dst`
error Exit status 1
error Failed at the # build script 'jade -P -H src -o dst'.
error Make sure you have the latest version of node.js and npm installed.
error If you do, this is most likely a problem with the package,
error not with npm itself.
error Tell the author that this fails on your system:
error jade -P -H src -o dst
error You can get information on how to open an issue for this project with:
error npm bugs
error Or if that isn't available, you can get their info via:
error npm owner ls
error There is likely additional logging output above.
verbose exit [ 1, true ]
If -H is excluded everything runs fine. What seems to be the problem?
npm version: 6.9.1
jade version: 1.11.0
Issue has been resolved. My mistake was that I thought jade-cli was part of common jade package. Appears that you have to install it separately using
npm i jade-cli -g
-g for installing it globally.
After this compilation goes successfully and creates all necessary folder architecture
I would like to try and setup Reaction Commerce this reaction-doc. When I run reaction init, NPM error occurs in installing NPM packages.
5868 verbose stack Error: Command failed: git -c core.longpaths=true clone --template=C:\Users\..\AppData\Roaming\npm-cache\_git-remotes\_templates --mirror git#github.com:ongoworks/node-authorize-net.git C:\Users\..\AppData\Roaming\npm-cache\_git-remotes\git-github-com-ongoworks-node-authorize-net-git-e88b3c4b
5868 verbose stack Cloning into bare repository 'C:\Users\...\AppData\Roaming\npm-cache\_git-remotes\git-github-com-ongoworks-node-authorize-net-git-e88b3c4b'...
5868 verbose stack Host key verification failed.
5868 verbose stack fatal: Could not read from remote repository.
5868 verbose stack
5868 verbose stack Please make sure you have the correct access rights
5868 verbose stack and the repository exists.
5868 verbose stack
5868 verbose stack at ChildProcess.exithandler (child_process.js:213:12)
5868 verbose stack at emitTwo (events.js:87:13)
5868 verbose stack at ChildProcess.emit (events.js:172:7)
5868 verbose stack at maybeClose (internal/child_process.js:829:16)
5868 verbose stack at Process.ChildProcess._handle.onexit (internal/child_process.js:211:5)
5869 verbose cwd C:\Users\...\reaction
5870 error Windows_NT 6.1.7600
5871 error argv "C:\\Users\\...\\AppData\\Local\\.meteor\\packages\\meteor-tool\\1.4.1_1\\mt-os.windows.x86_32\\dev_bundle\\bin\\node.exe" "C:\\Users\\...\\AppData\\Local\\.meteor\\packages\\meteor-tool\\1.4.1_1\\mt-os.windows.x86_32\\dev_bundle\\lib\\node_modules\\npm\\bin\\npm-cli.js" "install"
5872 error node v4.5.0
5873 error npm v3.10.6
5874 error code 128
5875 error Command failed: git -c core.longpaths=true clone --template=C:\Users\...\AppData\Roaming\npm-cache\_git-remotes\_templates --mirror git#github.com:ongoworks/node-authorize-net.git C:\Users\...\AppData\Roaming\npm-cache\_git-remotes\git-github-com-ongoworks-node-authorize-net-git-e88b3c4b
5875 error Cloning into bare repository 'C:\Users\...\AppData\Roaming\npm-cache\_git-remotes\git-github-com-ongoworks-node-authorize-net-git-e88b3c4b'...
5875 error Host key verification failed.
5875 error fatal: Could not read from remote repository.
5875 error
5875 error Please make sure you have the correct access rights
5875 error and the repository exists.
5876 error If you need help, you may report this error at:
5876 error <https://github.com/npm/npm/issues>
5877 verbose exit [ 1, true ]
I found Host key verification failed and Please make sure you have the correct access rights. I already created ssh key in my github account. I can login successfully from Git Bash command(ssh -T git#github.com).
Do I need special access key for reaction commerce? I am confused this problem is git bash configuration problem or key verification problem in Reaction. Cos I have no experience in bit bash command.
I got the project from the Heroku startup guide and deployed it successfully. However when I try to run it locally I'm faced with this error:
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 'start' ]
2 info using npm#2.15.5
3 info using node#v4.4.5
4 verbose run-script [ 'prestart', 'start', 'poststart' ]
5 info prestart MEAN#1.0.0
6 info start MEAN#1.0.0
7 verbose unsafe-perm in lifecycle true
8 info MEAN#1.0.0 Failed to exec start script
9 verbose stack Error: MEAN#1.0.0 start: `node server.js`
9 verbose stack Exit status 1
9 verbose stack at EventEmitter.<anonymous> (C:\Program Files\nodejs\node_modules\npm\lib\utils\lifecycle.js:217:16)
9 verbose stack at emitTwo (events.js:87:13)
9 verbose stack at EventEmitter.emit (events.js:172:7)
9 verbose stack at ChildProcess.<anonymous> (C:\Program Files\nodejs\node_modules\npm\lib\utils\spawn.js:24:14)
9 verbose stack at emitTwo (events.js:87:13)
9 verbose stack at ChildProcess.emit (events.js:172:7)
9 verbose stack at maybeClose (internal/child_process.js:827:16)
9 verbose stack at Process.ChildProcess._handle.onexit (internal/child_process.js:211:5)
10 verbose pkgid MEAN#1.0.0
11 verbose cwd C:\Users\kmagl\Documents\CuttingEdge\new-project4
12 error Windows_NT 10.0.10586
13 error argv "C:\\Program Files\\nodejs\\node.exe" "C:\\Program Files\\nodejs\\node_modules\\npm\\bin\\npm-cli.js" "start"
14 error node v4.4.5
15 error npm v2.15.5
16 error code ELIFECYCLE
17 error MEAN#1.0.0 start: `node server.js`
17 error Exit status 1
18 error Failed at the MEAN#1.0.0 start script 'node server.js'.
18 error This is most likely a problem with the MEAN package,
18 error not with npm itself.
18 error Tell the author that this fails on your system:
18 error node server.js
18 error You can get information on how to open an issue for this project with:
18 error npm bugs MEAN
18 error Or if that isn't available, you can get their info via:
18 error
18 error npm owner ls MEAN
18 error There is likely additional logging output above.
19 verbose exit [ 1, true ]
I would love some help on this. I and some other people are having trouble at this point.
Make sure you've run npm install locally, and that you have an environment variable named MONGODB_URI that has a valid URL to a running mongodb instance.
Also, if you call node server.js from the command line, you may find more verbose logging to help you narrow down the problem; the one npm emits is usually pretty opaque.